From 0b7bfb62700ab0c0f8764dd04e7dc3d64835781d Mon Sep 17 00:00:00 2001 From: Dominik Riebeling Date: Sun, 9 Aug 2009 10:57:39 +0000 Subject: Extend bootloader installation to accept alternatives for the destination filename. Remove the hardcoded special case for the H10 bootloader installation and uninstallation. Allow multiple bootloader filenames to be present and pick the existing one on (un)installation. This is also needed for easily adding support for the Samsung YH players (to make FS#10373 actually work). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22220 a1c6a512-1295-4272-9138-f99709370657 --- rbutil/rbutilqt/base/bootloaderinstallbase.cpp | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'rbutil/rbutilqt/base/bootloaderinstallbase.cpp') diff --git a/rbutil/rbutilqt/base/bootloaderinstallbase.cpp b/rbutil/rbutilqt/base/bootloaderinstallbase.cpp index 54e06d024e..5ce735a5b7 100644 --- a/rbutil/rbutilqt/base/bootloaderinstallbase.cpp +++ b/rbutil/rbutilqt/base/bootloaderinstallbase.cpp @@ -187,3 +187,19 @@ QString BootloaderInstallBase::postinstallHints(QString model) return QString(""); } + +//! @brief set list of possible bootloader files and pick the existing one. +//! @param sl list of possible bootloader files. +void BootloaderInstallBase::setBlFile(QStringList sl) +{ + // figue which of the possible bootloader filenames is correct. + for(int a = 0; a < sl.size(); a++) { + if(!resolvePathCase(sl.at(a)).isEmpty()) { + m_blfile = sl.at(a); + } + } + if(m_blfile.isEmpty()) { + m_blfile = sl.at(0); + } +} + -- cgit v1.2.3