Merge pull request #2244 from opentx/profilebackupfolder_next
Profilebackupfolder next
This commit is contained in:
@@ -295,8 +295,10 @@ QString Profile::fwName() const { return _fwName; }
|
|||||||
QString Profile::fwType() const { return _fwType; }
|
QString Profile::fwType() const { return _fwType; }
|
||||||
QString Profile::name() const { return _name; }
|
QString Profile::name() const { return _name; }
|
||||||
QString Profile::sdPath() const { return _sdPath; }
|
QString Profile::sdPath() const { return _sdPath; }
|
||||||
|
QString Profile::pBackupDir() const { return _pBackupDir; }
|
||||||
QString Profile::splashFile() const { return _splashFile; }
|
QString Profile::splashFile() const { return _splashFile; }
|
||||||
bool Profile::burnFirmware() const { return _burnFirmware; }
|
bool Profile::burnFirmware() const { return _burnFirmware; }
|
||||||
|
bool Profile::penableBackup() const { return _penableBackup; }
|
||||||
bool Profile::renameFwFiles() const { return _renameFwFiles; }
|
bool Profile::renameFwFiles() const { return _renameFwFiles; }
|
||||||
int Profile::channelOrder() const { return _channelOrder; }
|
int Profile::channelOrder() const { return _channelOrder; }
|
||||||
int Profile::defaultMode() const { return _defaultMode; }
|
int Profile::defaultMode() const { return _defaultMode; }
|
||||||
@@ -322,9 +324,11 @@ void Profile::name (const QString x) { store(x, _name, "Name"
|
|||||||
void Profile::fwName (const QString x) { store(x, _fwName, "fwName" ,"Profiles", QString("profile%1").arg(index));}
|
void Profile::fwName (const QString x) { store(x, _fwName, "fwName" ,"Profiles", QString("profile%1").arg(index));}
|
||||||
void Profile::fwType (const QString x) { store(x, _fwType, "fwType" ,"Profiles", QString("profile%1").arg(index));}
|
void Profile::fwType (const QString x) { store(x, _fwType, "fwType" ,"Profiles", QString("profile%1").arg(index));}
|
||||||
void Profile::sdPath (const QString x) { store(x, _sdPath, "sdPath" ,"Profiles", QString("profile%1").arg(index));}
|
void Profile::sdPath (const QString x) { store(x, _sdPath, "sdPath" ,"Profiles", QString("profile%1").arg(index));}
|
||||||
|
void Profile::pBackupDir (const QString x) { store(x, _pBackupDir, "pBackupDir" ,"Profiles", QString("profile%1").arg(index));}
|
||||||
void Profile::splashFile (const QString x) { store(x, _splashFile, "SplashFileName" ,"Profiles", QString("profile%1").arg(index));}
|
void Profile::splashFile (const QString x) { store(x, _splashFile, "SplashFileName" ,"Profiles", QString("profile%1").arg(index));}
|
||||||
void Profile::burnFirmware (const bool x) { store(x, _burnFirmware, "burnFirmware" ,"Profiles", QString("profile%1").arg(index));}
|
void Profile::burnFirmware (const bool x) { store(x, _burnFirmware, "burnFirmware" ,"Profiles", QString("profile%1").arg(index));}
|
||||||
void Profile::renameFwFiles (const bool x) { store(x, _renameFwFiles, "rename_firmware_files" ,"Profiles", QString("profile%1").arg(index));}
|
void Profile::renameFwFiles (const bool x) { store(x, _renameFwFiles, "rename_firmware_files" ,"Profiles", QString("profile%1").arg(index));}
|
||||||
|
void Profile::penableBackup (const bool x) { store(x, _penableBackup, "penableBackup" ,"Profiles", QString("profile%1").arg(index));}
|
||||||
void Profile::channelOrder (const int x) { store(x, _channelOrder, "default_channel_order" ,"Profiles", QString("profile%1").arg(index));}
|
void Profile::channelOrder (const int x) { store(x, _channelOrder, "default_channel_order" ,"Profiles", QString("profile%1").arg(index));}
|
||||||
void Profile::defaultMode (const int x) { store(x, _defaultMode, "default_mode" ,"Profiles", QString("profile%1").arg(index));}
|
void Profile::defaultMode (const int x) { store(x, _defaultMode, "default_mode" ,"Profiles", QString("profile%1").arg(index));}
|
||||||
|
|
||||||
@@ -357,9 +361,11 @@ Profile& Profile::operator=(const Profile& rhs)
|
|||||||
fwName ( rhs.fwName() );
|
fwName ( rhs.fwName() );
|
||||||
fwType ( rhs.fwType() );
|
fwType ( rhs.fwType() );
|
||||||
sdPath ( rhs.sdPath() );
|
sdPath ( rhs.sdPath() );
|
||||||
|
pBackupDir ( rhs.pBackupDir() );
|
||||||
splashFile ( rhs.splashFile() );
|
splashFile ( rhs.splashFile() );
|
||||||
burnFirmware ( rhs.burnFirmware() );
|
burnFirmware ( rhs.burnFirmware() );
|
||||||
renameFwFiles( rhs.renameFwFiles() );
|
renameFwFiles( rhs.renameFwFiles() );
|
||||||
|
penableBackup( rhs.penableBackup() );
|
||||||
channelOrder ( rhs.channelOrder() );
|
channelOrder ( rhs.channelOrder() );
|
||||||
defaultMode ( rhs.defaultMode() );
|
defaultMode ( rhs.defaultMode() );
|
||||||
beeper ( rhs.beeper() );
|
beeper ( rhs.beeper() );
|
||||||
@@ -432,9 +438,11 @@ void Profile::init(int newIndex)
|
|||||||
_fwType = "";
|
_fwType = "";
|
||||||
_name = "";
|
_name = "";
|
||||||
_sdPath = "";
|
_sdPath = "";
|
||||||
|
_pBackupDir = "";
|
||||||
_splashFile = "";
|
_splashFile = "";
|
||||||
_burnFirmware = false;
|
_burnFirmware = false;
|
||||||
_renameFwFiles = false;
|
_renameFwFiles = false;
|
||||||
|
_penableBackup = false;
|
||||||
_channelOrder = 0;
|
_channelOrder = 0;
|
||||||
_defaultMode = 1;
|
_defaultMode = 1;
|
||||||
|
|
||||||
@@ -454,8 +462,10 @@ void Profile::flush()
|
|||||||
getset( _fwType, "fwType" ,"" ,"Profiles", QString("profile%1").arg(index));
|
getset( _fwType, "fwType" ,"" ,"Profiles", QString("profile%1").arg(index));
|
||||||
getset( _name, "Name" ,"" ,"Profiles", QString("profile%1").arg(index));
|
getset( _name, "Name" ,"" ,"Profiles", QString("profile%1").arg(index));
|
||||||
getset( _sdPath, "sdPath" ,"" ,"Profiles", QString("profile%1").arg(index));
|
getset( _sdPath, "sdPath" ,"" ,"Profiles", QString("profile%1").arg(index));
|
||||||
|
getset( _pBackupDir, "pBackupDir" ,"" ,"Profiles", QString("profile%1").arg(index));
|
||||||
getset( _splashFile, "SplashFileName" ,"" ,"Profiles", QString("profile%1").arg(index));
|
getset( _splashFile, "SplashFileName" ,"" ,"Profiles", QString("profile%1").arg(index));
|
||||||
getset( _burnFirmware, "burnFirmware" ,false ,"Profiles", QString("profile%1").arg(index));
|
getset( _burnFirmware, "burnFirmware" ,false ,"Profiles", QString("profile%1").arg(index));
|
||||||
|
getset( _penableBackup, "penableBackup" ,false ,"Profiles", QString("profile%1").arg(index));
|
||||||
getset( _renameFwFiles, "rename_firmware_files" ,false ,"Profiles", QString("profile%1").arg(index));
|
getset( _renameFwFiles, "rename_firmware_files" ,false ,"Profiles", QString("profile%1").arg(index));
|
||||||
getset( _channelOrder, "default_channel_order" ,0 ,"Profiles", QString("profile%1").arg(index));
|
getset( _channelOrder, "default_channel_order" ,0 ,"Profiles", QString("profile%1").arg(index));
|
||||||
getset( _defaultMode, "default_mode" ,1 ,"Profiles", QString("profile%1").arg(index));
|
getset( _defaultMode, "default_mode" ,1 ,"Profiles", QString("profile%1").arg(index));
|
||||||
@@ -682,8 +692,8 @@ AppData::AppData()
|
|||||||
settings.remove("compilation-server");
|
settings.remove("compilation-server");
|
||||||
|
|
||||||
// Load and store all variables. Use default values if setting values are missing
|
// Load and store all variables. Use default values if setting values are missing
|
||||||
QString _tempString; // Do not touch. Do not change the settings version before a new verson update!
|
QString _tempString; // Do not touch. Do not change the settings version before a new verson update!
|
||||||
getset( _tempString, "settings_version" ,"20" ); // This is a version marker. Will be used to upgrade the settings later on.
|
getset( _tempString, "settings_version" ,"210" ); // This is a version marker. Will be used to upgrade the settings later on.
|
||||||
|
|
||||||
getset( _recentFiles, "recentFileList" ,"" );
|
getset( _recentFiles, "recentFileList" ,"" );
|
||||||
getset( _mainWinGeo, "mainWindowGeometry" ,"" );
|
getset( _mainWinGeo, "mainWindowGeometry" ,"" );
|
||||||
|
|||||||
@@ -107,8 +107,10 @@ class Profile: protected CompStoreObj
|
|||||||
QString _fwType;
|
QString _fwType;
|
||||||
QString _name;
|
QString _name;
|
||||||
QString _sdPath;
|
QString _sdPath;
|
||||||
|
QString _pBackupDir;
|
||||||
QString _splashFile;
|
QString _splashFile;
|
||||||
bool _burnFirmware;
|
bool _burnFirmware;
|
||||||
|
bool _penableBackup;
|
||||||
bool _renameFwFiles;
|
bool _renameFwFiles;
|
||||||
int _channelOrder;
|
int _channelOrder;
|
||||||
int _defaultMode;
|
int _defaultMode;
|
||||||
@@ -136,9 +138,11 @@ class Profile: protected CompStoreObj
|
|||||||
QString fwType() const;
|
QString fwType() const;
|
||||||
QString name() const;
|
QString name() const;
|
||||||
QString sdPath() const;
|
QString sdPath() const;
|
||||||
|
QString pBackupDir() const;
|
||||||
QString splashFile() const;
|
QString splashFile() const;
|
||||||
bool burnFirmware() const;
|
bool burnFirmware() const;
|
||||||
bool renameFwFiles() const;
|
bool renameFwFiles() const;
|
||||||
|
bool penableBackup() const;
|
||||||
int channelOrder() const;
|
int channelOrder() const;
|
||||||
int defaultMode() const;
|
int defaultMode() const;
|
||||||
|
|
||||||
@@ -163,9 +167,11 @@ class Profile: protected CompStoreObj
|
|||||||
void fwName (const QString);
|
void fwName (const QString);
|
||||||
void fwType (const QString);
|
void fwType (const QString);
|
||||||
void sdPath (const QString);
|
void sdPath (const QString);
|
||||||
|
void pBackupDir (const QString);
|
||||||
void splashFile (const QString);
|
void splashFile (const QString);
|
||||||
void burnFirmware (const bool);
|
void burnFirmware (const bool);
|
||||||
void renameFwFiles (const bool);
|
void renameFwFiles (const bool);
|
||||||
|
void penableBackup (const bool);
|
||||||
void channelOrder (const int);
|
void channelOrder (const int);
|
||||||
void defaultMode (const int);
|
void defaultMode (const int);
|
||||||
|
|
||||||
|
|||||||
@@ -66,6 +66,8 @@ void AppPreferencesDialog::writeValues()
|
|||||||
g.profile[g.id()].renameFwFiles(ui->renameFirmware->isChecked());
|
g.profile[g.id()].renameFwFiles(ui->renameFirmware->isChecked());
|
||||||
g.profile[g.id()].burnFirmware(ui->burnFirmware->isChecked());
|
g.profile[g.id()].burnFirmware(ui->burnFirmware->isChecked());
|
||||||
g.profile[g.id()].sdPath(ui->sdPath->text());
|
g.profile[g.id()].sdPath(ui->sdPath->text());
|
||||||
|
g.profile[g.id()].pBackupDir(ui->profilebackupPath->text());
|
||||||
|
g.profile[g.id()].penableBackup(ui->pbackupEnable->isChecked());
|
||||||
g.profile[g.id()].splashFile(ui->SplashFileName->text());
|
g.profile[g.id()].splashFile(ui->SplashFileName->text());
|
||||||
|
|
||||||
// The profile name may NEVER be empty
|
// The profile name may NEVER be empty
|
||||||
@@ -164,6 +166,18 @@ void AppPreferencesDialog::initSettings()
|
|||||||
ui->stickmodeCB->setCurrentIndex(g.profile[g.id()].defaultMode());
|
ui->stickmodeCB->setCurrentIndex(g.profile[g.id()].defaultMode());
|
||||||
ui->renameFirmware->setChecked(g.profile[g.id()].renameFwFiles());
|
ui->renameFirmware->setChecked(g.profile[g.id()].renameFwFiles());
|
||||||
ui->sdPath->setText(g.profile[g.id()].sdPath());
|
ui->sdPath->setText(g.profile[g.id()].sdPath());
|
||||||
|
if (!g.profile[g.id()].pBackupDir().isEmpty()) {
|
||||||
|
if (QDir(g.profile[g.id()].pBackupDir()).exists()) {
|
||||||
|
ui->profilebackupPath->setText(g.profile[g.id()].pBackupDir());
|
||||||
|
ui->pbackupEnable->setEnabled(true);
|
||||||
|
ui->pbackupEnable->setChecked(g.profile[g.id()].penableBackup());
|
||||||
|
} else {
|
||||||
|
ui->pbackupEnable->setDisabled(true);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
ui->pbackupEnable->setDisabled(true);
|
||||||
|
}
|
||||||
|
|
||||||
ui->profileNameLE->setText(g.profile[g.id()].name());
|
ui->profileNameLE->setText(g.profile[g.id()].name());
|
||||||
ui->SplashFileName->setText(g.profile[g.id()].splashFile());
|
ui->SplashFileName->setText(g.profile[g.id()].splashFile());
|
||||||
|
|
||||||
@@ -224,8 +238,17 @@ void AppPreferencesDialog::on_backupPathButton_clicked()
|
|||||||
if (!fileName.isEmpty()) {
|
if (!fileName.isEmpty()) {
|
||||||
g.backupDir(fileName);
|
g.backupDir(fileName);
|
||||||
ui->backupPath->setText(fileName);
|
ui->backupPath->setText(fileName);
|
||||||
|
ui->backupEnable->setEnabled(true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void AppPreferencesDialog::on_ProfilebackupPathButton_clicked()
|
||||||
|
{
|
||||||
|
QString fileName = QFileDialog::getExistingDirectory(this,tr("Select your Models and Settings backup folder"), g.backupDir());
|
||||||
|
if (!fileName.isEmpty()) {
|
||||||
|
ui->profilebackupPath->setText(fileName);
|
||||||
|
ui->pbackupEnable->setEnabled(true);
|
||||||
}
|
}
|
||||||
ui->backupEnable->setEnabled(true);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void AppPreferencesDialog::on_ge_pathButton_clicked()
|
void AppPreferencesDialog::on_ge_pathButton_clicked()
|
||||||
|
|||||||
@@ -47,8 +47,9 @@ class AppPreferencesDialog : public QDialog
|
|||||||
void on_snapshotPathButton_clicked();
|
void on_snapshotPathButton_clicked();
|
||||||
void on_snapshotClipboardCKB_clicked();
|
void on_snapshotClipboardCKB_clicked();
|
||||||
void on_backupPathButton_clicked();
|
void on_backupPathButton_clicked();
|
||||||
|
void on_ProfilebackupPathButton_clicked();
|
||||||
void on_ge_pathButton_clicked();
|
void on_ge_pathButton_clicked();
|
||||||
|
|
||||||
void on_sdPathButton_clicked();
|
void on_sdPathButton_clicked();
|
||||||
void on_removeProfileButton_clicked();
|
void on_removeProfileButton_clicked();
|
||||||
void on_SplashSelect_clicked();
|
void on_SplashSelect_clicked();
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>685</width>
|
<width>686</width>
|
||||||
<height>550</height>
|
<height>550</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
@@ -26,13 +26,7 @@
|
|||||||
<string>Edit Settings</string>
|
<string>Edit Settings</string>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QGridLayout" name="gridLayout">
|
<layout class="QGridLayout" name="gridLayout">
|
||||||
<property name="verticalSpacing">
|
<item row="1" column="0">
|
||||||
<number>2</number>
|
|
||||||
</property>
|
|
||||||
<property name="margin">
|
|
||||||
<number>6</number>
|
|
||||||
</property>
|
|
||||||
<item row="2" column="0" colspan="2">
|
|
||||||
<widget class="QDialogButtonBox" name="buttonBox">
|
<widget class="QDialogButtonBox" name="buttonBox">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
@@ -42,7 +36,7 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="1">
|
<item row="0" column="0">
|
||||||
<widget class="QTabWidget" name="tabWidget">
|
<widget class="QTabWidget" name="tabWidget">
|
||||||
<property name="currentIndex">
|
<property name="currentIndex">
|
||||||
<number>0</number>
|
<number>0</number>
|
||||||
@@ -51,110 +45,8 @@
|
|||||||
<attribute name="title">
|
<attribute name="title">
|
||||||
<string>Radio Profile</string>
|
<string>Radio Profile</string>
|
||||||
</attribute>
|
</attribute>
|
||||||
<layout class="QGridLayout" name="gridLayout_2" columnstretch="0,0,1,0,0,0,0,0">
|
<layout class="QGridLayout" name="gridLayout_2" columnstretch="0,1,0,0">
|
||||||
<item row="21" column="7">
|
<item row="0" column="0">
|
||||||
<widget class="QPushButton" name="sdPathButton">
|
|
||||||
<property name="text">
|
|
||||||
<string>Open Folder</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="25" column="0">
|
|
||||||
<widget class="QLabel" name="label_13">
|
|
||||||
<property name="sizePolicy">
|
|
||||||
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Preferred">
|
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>0</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string>Default Channel Order</string>
|
|
||||||
</property>
|
|
||||||
<property name="alignment">
|
|
||||||
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="9" column="0">
|
|
||||||
<widget class="QLabel" name="label_6">
|
|
||||||
<property name="text">
|
|
||||||
<string>Build Options</string>
|
|
||||||
</property>
|
|
||||||
<property name="alignment">
|
|
||||||
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="7" column="0">
|
|
||||||
<widget class="QLabel" name="langLabel">
|
|
||||||
<property name="text">
|
|
||||||
<string>Menu Language</string>
|
|
||||||
</property>
|
|
||||||
<property name="alignment">
|
|
||||||
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="23" column="0">
|
|
||||||
<widget class="QLabel" name="label_14">
|
|
||||||
<property name="sizePolicy">
|
|
||||||
<sizepolicy hsizetype="Preferred" vsizetype="Minimum">
|
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>0</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string>Default Stick Mode</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="14" column="7">
|
|
||||||
<widget class="QPushButton" name="SplashSelect">
|
|
||||||
<property name="text">
|
|
||||||
<string>Select Image</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="22" column="1">
|
|
||||||
<widget class="QLabel" name="lblGeneralSettings">
|
|
||||||
<property name="enabled">
|
|
||||||
<bool>true</bool>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string notr="true">General Settings Label</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="10" column="0" colspan="8">
|
|
||||||
<widget class="Line" name="line_7">
|
|
||||||
<property name="orientation">
|
|
||||||
<enum>Qt::Horizontal</enum>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="9" column="1" colspan="7">
|
|
||||||
<layout class="QGridLayout" name="optionsLayout"/>
|
|
||||||
</item>
|
|
||||||
<item row="14" column="0">
|
|
||||||
<widget class="QLabel" name="label_8">
|
|
||||||
<property name="sizePolicy">
|
|
||||||
<sizepolicy hsizetype="Preferred" vsizetype="Minimum">
|
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>0</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
<property name="font">
|
|
||||||
<font>
|
|
||||||
<weight>75</weight>
|
|
||||||
<bold>true</bold>
|
|
||||||
</font>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string>Splash Screen</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="0">
|
|
||||||
<widget class="QLabel" name="label_2">
|
<widget class="QLabel" name="label_2">
|
||||||
<property name="font">
|
<property name="font">
|
||||||
<font>
|
<font>
|
||||||
@@ -167,51 +59,17 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="17" column="7">
|
<item row="0" column="1">
|
||||||
<widget class="QPushButton" name="clearImageButton">
|
<widget class="QLineEdit" name="profileNameLE"/>
|
||||||
<property name="text">
|
</item>
|
||||||
<string>Clear Image</string>
|
<item row="1" column="0" colspan="4">
|
||||||
|
<widget class="Line" name="line_8">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="17" column="1">
|
<item row="2" column="0">
|
||||||
<widget class="QLabel" name="imageLabel">
|
|
||||||
<property name="sizePolicy">
|
|
||||||
<sizepolicy hsizetype="Minimum" vsizetype="Minimum">
|
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>0</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>128</width>
|
|
||||||
<height>64</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="maximumSize">
|
|
||||||
<size>
|
|
||||||
<width>212</width>
|
|
||||||
<height>64</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="frameShape">
|
|
||||||
<enum>QFrame::Panel</enum>
|
|
||||||
</property>
|
|
||||||
<property name="frameShadow">
|
|
||||||
<enum>QFrame::Plain</enum>
|
|
||||||
</property>
|
|
||||||
<property name="lineWidth">
|
|
||||||
<number>1</number>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string/>
|
|
||||||
</property>
|
|
||||||
<property name="scaledContents">
|
|
||||||
<bool>true</bool>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="5" column="0">
|
|
||||||
<widget class="QLabel" name="label_7">
|
<widget class="QLabel" name="label_7">
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
<sizepolicy hsizetype="Preferred" vsizetype="Minimum">
|
<sizepolicy hsizetype="Preferred" vsizetype="Minimum">
|
||||||
@@ -234,57 +92,24 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="19" column="0" colspan="8">
|
<item row="2" column="1">
|
||||||
<widget class="Line" name="line_6">
|
<widget class="QComboBox" name="downloadVerCB">
|
||||||
<property name="orientation">
|
<property name="enabled">
|
||||||
<enum>Qt::Horizontal</enum>
|
<bool>true</bool>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="2" column="0" colspan="8">
|
<item row="3" column="0">
|
||||||
<widget class="Line" name="line_8">
|
<widget class="QLabel" name="langLabel">
|
||||||
<property name="orientation">
|
|
||||||
<enum>Qt::Horizontal</enum>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="20" column="0">
|
|
||||||
<widget class="QLabel" name="label">
|
|
||||||
<property name="font">
|
|
||||||
<font>
|
|
||||||
<weight>75</weight>
|
|
||||||
<bold>true</bold>
|
|
||||||
</font>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Other Settings</string>
|
<string>Menu Language</string>
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="22" column="0">
|
|
||||||
<widget class="QLabel" name="label_4">
|
|
||||||
<property name="text">
|
|
||||||
<string>General Settings</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="21" column="0">
|
|
||||||
<widget class="QLabel" name="sdPathLabel">
|
|
||||||
<property name="sizePolicy">
|
|
||||||
<sizepolicy hsizetype="Preferred" vsizetype="Minimum">
|
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>0</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string>SD Structure path</string>
|
|
||||||
</property>
|
</property>
|
||||||
<property name="alignment">
|
<property name="alignment">
|
||||||
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
|
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="7" column="1" colspan="7">
|
<item row="3" column="1">
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout" stretch="1,1,1">
|
<layout class="QHBoxLayout" name="horizontalLayout" stretch="1,1,1">
|
||||||
<property name="sizeConstraint">
|
<property name="sizeConstraint">
|
||||||
<enum>QLayout::SetDefaultConstraint</enum>
|
<enum>QLayout::SetDefaultConstraint</enum>
|
||||||
@@ -338,14 +163,46 @@ May be different from firmware language</string>
|
|||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
<item row="5" column="1" colspan="7">
|
<item row="4" column="0">
|
||||||
<widget class="QComboBox" name="downloadVerCB">
|
<widget class="QLabel" name="label_6">
|
||||||
<property name="enabled">
|
<property name="text">
|
||||||
<bool>true</bool>
|
<string>Build Options</string>
|
||||||
|
</property>
|
||||||
|
<property name="alignment">
|
||||||
|
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="14" column="1" colspan="6">
|
<item row="4" column="1">
|
||||||
|
<layout class="QGridLayout" name="optionsLayout"/>
|
||||||
|
</item>
|
||||||
|
<item row="5" column="0" colspan="4">
|
||||||
|
<widget class="Line" name="line_7">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="6" column="0">
|
||||||
|
<widget class="QLabel" name="label_8">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Preferred" vsizetype="Minimum">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<weight>75</weight>
|
||||||
|
<bold>true</bold>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>Splash Screen</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="6" column="1">
|
||||||
<widget class="QLineEdit" name="SplashFileName">
|
<widget class="QLineEdit" name="SplashFileName">
|
||||||
<property name="enabled">
|
<property name="enabled">
|
||||||
<bool>true</bool>
|
<bool>true</bool>
|
||||||
@@ -355,17 +212,150 @@ May be different from firmware language</string>
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="21" column="1" colspan="6">
|
<item row="7" column="1">
|
||||||
|
<widget class="QLabel" name="imageLabel">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Minimum" vsizetype="Minimum">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="minimumSize">
|
||||||
|
<size>
|
||||||
|
<width>128</width>
|
||||||
|
<height>64</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="maximumSize">
|
||||||
|
<size>
|
||||||
|
<width>212</width>
|
||||||
|
<height>64</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="frameShape">
|
||||||
|
<enum>QFrame::Panel</enum>
|
||||||
|
</property>
|
||||||
|
<property name="frameShadow">
|
||||||
|
<enum>QFrame::Plain</enum>
|
||||||
|
</property>
|
||||||
|
<property name="lineWidth">
|
||||||
|
<number>1</number>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string/>
|
||||||
|
</property>
|
||||||
|
<property name="scaledContents">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="8" column="0" colspan="4">
|
||||||
|
<widget class="Line" name="line_6">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="9" column="0">
|
||||||
|
<widget class="QLabel" name="label">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<weight>75</weight>
|
||||||
|
<bold>true</bold>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>Other Settings</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="10" column="0">
|
||||||
|
<widget class="QLabel" name="sdPathLabel">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Preferred" vsizetype="Minimum">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>SD Structure path</string>
|
||||||
|
</property>
|
||||||
|
<property name="alignment">
|
||||||
|
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="10" column="1">
|
||||||
<widget class="QLineEdit" name="sdPath">
|
<widget class="QLineEdit" name="sdPath">
|
||||||
<property name="enabled">
|
<property name="enabled">
|
||||||
<bool>true</bool>
|
<bool>true</bool>
|
||||||
</property>
|
</property>
|
||||||
<property name="readOnly">
|
<property name="readOnly">
|
||||||
<bool>true</bool>
|
<bool>false</bool>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="23" column="1" colspan="6">
|
<item row="11" column="0">
|
||||||
|
<widget class="QLabel" name="profilebackupPathLabel">
|
||||||
|
<property name="toolTip">
|
||||||
|
<string>The profile specific folder, if set, will override general Backup folder</string>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>Backup folder</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="11" column="1">
|
||||||
|
<widget class="QLineEdit" name="profilebackupPath">
|
||||||
|
<property name="toolTip">
|
||||||
|
<string>If set it will override the application general setting</string>
|
||||||
|
</property>
|
||||||
|
<property name="readOnly">
|
||||||
|
<bool>false</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="12" column="1">
|
||||||
|
<widget class="QCheckBox" name="pbackupEnable">
|
||||||
|
<property name="toolTip">
|
||||||
|
<string>if set, will override general backup enable</string>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>Enable automatic backup before writing firmware</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="13" column="0">
|
||||||
|
<widget class="QLabel" name="label_4">
|
||||||
|
<property name="text">
|
||||||
|
<string>General Settings</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="13" column="1">
|
||||||
|
<widget class="QLabel" name="lblGeneralSettings">
|
||||||
|
<property name="enabled">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string notr="true">General Settings Label</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="14" column="0">
|
||||||
|
<widget class="QLabel" name="label_14">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Preferred" vsizetype="Minimum">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>Default Stick Mode</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="14" column="1">
|
||||||
<widget class="QComboBox" name="stickmodeCB">
|
<widget class="QComboBox" name="stickmodeCB">
|
||||||
<property name="maximumSize">
|
<property name="maximumSize">
|
||||||
<size>
|
<size>
|
||||||
@@ -419,7 +409,23 @@ Mode 4:
|
|||||||
</item>
|
</item>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="25" column="1" colspan="6">
|
<item row="15" column="0">
|
||||||
|
<widget class="QLabel" name="label_13">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Preferred">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>Default Channel Order</string>
|
||||||
|
</property>
|
||||||
|
<property name="alignment">
|
||||||
|
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="15" column="1">
|
||||||
<widget class="QComboBox" name="channelorderCB">
|
<widget class="QComboBox" name="channelorderCB">
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed">
|
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed">
|
||||||
@@ -567,31 +573,21 @@ Mode 4:
|
|||||||
</item>
|
</item>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="1" colspan="6">
|
<item row="16" column="1">
|
||||||
<widget class="QLineEdit" name="profileNameLE"/>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="7">
|
|
||||||
<widget class="QPushButton" name="removeProfileButton">
|
|
||||||
<property name="text">
|
|
||||||
<string>Remove Profile</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="26" column="1" colspan="7">
|
|
||||||
<widget class="QCheckBox" name="renameFirmware">
|
<widget class="QCheckBox" name="renameFirmware">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Append version number to FW file name</string>
|
<string>Append version number to FW file name</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="27" column="1" colspan="7">
|
<item row="17" column="1">
|
||||||
<widget class="QCheckBox" name="burnFirmware">
|
<widget class="QCheckBox" name="burnFirmware">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Offer to write FW to Tx after download</string>
|
<string>Offer to write FW to Tx after download</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="28" column="1">
|
<item row="18" column="1">
|
||||||
<spacer name="verticalSpacer_3">
|
<spacer name="verticalSpacer_3">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Vertical</enum>
|
<enum>Qt::Vertical</enum>
|
||||||
@@ -604,6 +600,44 @@ Mode 4:
|
|||||||
</property>
|
</property>
|
||||||
</spacer>
|
</spacer>
|
||||||
</item>
|
</item>
|
||||||
|
<item row="7" column="2" colspan="2">
|
||||||
|
<widget class="QPushButton" name="clearImageButton">
|
||||||
|
<property name="text">
|
||||||
|
<string>Clear Image</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="6" column="2" colspan="2">
|
||||||
|
<widget class="QPushButton" name="SplashSelect">
|
||||||
|
<property name="text">
|
||||||
|
<string>Select Image</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="2" colspan="2">
|
||||||
|
<widget class="QPushButton" name="removeProfileButton">
|
||||||
|
<property name="text">
|
||||||
|
<string>Remove Profile</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="10" column="2" colspan="2">
|
||||||
|
<widget class="QPushButton" name="sdPathButton">
|
||||||
|
<property name="text">
|
||||||
|
<string>Open Folder</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="11" column="2" colspan="2">
|
||||||
|
<widget class="QPushButton" name="ProfilebackupPathButton">
|
||||||
|
<property name="toolTip">
|
||||||
|
<string>The profile specific folder, if set, will override general Backup folder</string>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>Open Folder</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
<widget class="QWidget" name="applicationTab">
|
<widget class="QWidget" name="applicationTab">
|
||||||
@@ -611,17 +645,7 @@ Mode 4:
|
|||||||
<string>Application Settings</string>
|
<string>Application Settings</string>
|
||||||
</attribute>
|
</attribute>
|
||||||
<layout class="QGridLayout" name="gridLayout_3">
|
<layout class="QGridLayout" name="gridLayout_3">
|
||||||
<item row="4" column="1" colspan="4">
|
<item row="7" column="1" colspan="3">
|
||||||
<widget class="QCheckBox" name="showSplash">
|
|
||||||
<property name="text">
|
|
||||||
<string>Show splash screen when Companion starts</string>
|
|
||||||
</property>
|
|
||||||
<property name="checked">
|
|
||||||
<bool>true</bool>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="7" column="1" colspan="4">
|
|
||||||
<widget class="QCheckBox" name="startupCheck_companion9x">
|
<widget class="QCheckBox" name="startupCheck_companion9x">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Automatic check for Companion updates</string>
|
<string>Automatic check for Companion updates</string>
|
||||||
@@ -631,28 +655,38 @@ Mode 4:
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="10" column="1" colspan="4">
|
<item row="4" column="1" colspan="3">
|
||||||
|
<widget class="QCheckBox" name="showSplash">
|
||||||
|
<property name="text">
|
||||||
|
<string>Show splash screen when Companion starts</string>
|
||||||
|
</property>
|
||||||
|
<property name="checked">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="10" column="1" colspan="3">
|
||||||
<widget class="QCheckBox" name="backupEnable">
|
<widget class="QCheckBox" name="backupEnable">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Enable automatic backup before writing firmware</string>
|
<string>Enable automatic backup before writing firmware</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="3" column="1" colspan="4">
|
<item row="3" column="1" colspan="3">
|
||||||
<widget class="Line" name="line">
|
<widget class="Line" name="line">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="8" column="1" colspan="4">
|
<item row="8" column="1" colspan="3">
|
||||||
<widget class="Line" name="line_2">
|
<widget class="Line" name="line_2">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="6" column="1" colspan="4">
|
<item row="6" column="1" colspan="3">
|
||||||
<widget class="QCheckBox" name="startupCheck_fw">
|
<widget class="QCheckBox" name="startupCheck_fw">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Automatic check for OpenTX firmware updates</string>
|
<string>Automatic check for OpenTX firmware updates</string>
|
||||||
@@ -662,29 +696,6 @@ Mode 4:
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="13" column="1">
|
|
||||||
<widget class="QLineEdit" name="libraryPath">
|
|
||||||
<property name="enabled">
|
|
||||||
<bool>true</bool>
|
|
||||||
</property>
|
|
||||||
<property name="readOnly">
|
|
||||||
<bool>true</bool>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="3">
|
|
||||||
<spacer name="horizontalSpacer_4">
|
|
||||||
<property name="orientation">
|
|
||||||
<enum>Qt::Horizontal</enum>
|
|
||||||
</property>
|
|
||||||
<property name="sizeHint" stdset="0">
|
|
||||||
<size>
|
|
||||||
<width>40</width>
|
|
||||||
<height>20</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</spacer>
|
|
||||||
</item>
|
|
||||||
<item row="15" column="1">
|
<item row="15" column="1">
|
||||||
<spacer name="verticalSpacer_2">
|
<spacer name="verticalSpacer_2">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
@@ -698,13 +709,6 @@ Mode 4:
|
|||||||
</property>
|
</property>
|
||||||
</spacer>
|
</spacer>
|
||||||
</item>
|
</item>
|
||||||
<item row="9" column="4">
|
|
||||||
<widget class="QPushButton" name="backupPathButton">
|
|
||||||
<property name="text">
|
|
||||||
<string>Open Folder</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="12" column="0">
|
<item row="12" column="0">
|
||||||
<widget class="QLabel" name="label_10">
|
<widget class="QLabel" name="label_10">
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
@@ -731,40 +735,13 @@ Mode 4:
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="0" column="4">
|
<item row="1" column="1" colspan="3">
|
||||||
<widget class="QPushButton" name="ge_pathButton">
|
|
||||||
<property name="text">
|
|
||||||
<string>Find Executable</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="1" colspan="4">
|
|
||||||
<widget class="Line" name="line_4">
|
<widget class="Line" name="line_4">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="13" column="4">
|
|
||||||
<widget class="QPushButton" name="libraryPathButton">
|
|
||||||
<property name="text">
|
|
||||||
<string>Open Folder</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="9" column="1">
|
|
||||||
<widget class="QLineEdit" name="backupPath">
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>350</width>
|
|
||||||
<height>0</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="readOnly">
|
|
||||||
<bool>true</bool>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="0">
|
<item row="0" column="0">
|
||||||
<widget class="QLabel" name="ge_label">
|
<widget class="QLabel" name="ge_label">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
@@ -772,26 +749,6 @@ Mode 4:
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="12" column="1">
|
|
||||||
<widget class="QComboBox" name="splashincludeCB">
|
|
||||||
<property name="sizePolicy">
|
|
||||||
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
|
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>0</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
<item>
|
|
||||||
<property name="text">
|
|
||||||
<string>Only show user splash images</string>
|
|
||||||
</property>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<property name="text">
|
|
||||||
<string>Show user and companion splash images</string>
|
|
||||||
</property>
|
|
||||||
</item>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="13" column="0">
|
<item row="13" column="0">
|
||||||
<widget class="QLabel" name="label_9">
|
<widget class="QLabel" name="label_9">
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
@@ -834,18 +791,69 @@ Mode 4:
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="0" column="2">
|
<item row="11" column="1" colspan="3">
|
||||||
<spacer name="horizontalSpacer_3">
|
<widget class="Line" name="line_5">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeHint" stdset="0">
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="5" column="1" colspan="3">
|
||||||
|
<widget class="QCheckBox" name="modelWizard_CB">
|
||||||
|
<property name="text">
|
||||||
|
<string>Use model wizard when creating a new model</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="13" column="1">
|
||||||
|
<widget class="QLineEdit" name="libraryPath">
|
||||||
|
<property name="enabled">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
<property name="readOnly">
|
||||||
|
<bool>false</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="12" column="1">
|
||||||
|
<widget class="QComboBox" name="splashincludeCB">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<item>
|
||||||
|
<property name="text">
|
||||||
|
<string>Only show user splash images</string>
|
||||||
|
</property>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<property name="text">
|
||||||
|
<string>Show user and companion splash images</string>
|
||||||
|
</property>
|
||||||
|
</item>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="9" column="1">
|
||||||
|
<widget class="QLineEdit" name="backupPath">
|
||||||
|
<property name="minimumSize">
|
||||||
<size>
|
<size>
|
||||||
<width>40</width>
|
<width>350</width>
|
||||||
<height>20</height>
|
<height>0</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
</spacer>
|
<property name="readOnly">
|
||||||
|
<bool>false</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="9" column="2" colspan="2">
|
||||||
|
<widget class="QPushButton" name="backupPathButton">
|
||||||
|
<property name="text">
|
||||||
|
<string>Open Folder</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="0" column="1">
|
<item row="0" column="1">
|
||||||
<widget class="QLineEdit" name="ge_lineedit">
|
<widget class="QLineEdit" name="ge_lineedit">
|
||||||
@@ -860,17 +868,17 @@ Mode 4:
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="11" column="1" colspan="4">
|
<item row="0" column="2" colspan="2">
|
||||||
<widget class="Line" name="line_5">
|
<widget class="QPushButton" name="ge_pathButton">
|
||||||
<property name="orientation">
|
<property name="text">
|
||||||
<enum>Qt::Horizontal</enum>
|
<string>Find Executable</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="5" column="1" colspan="4">
|
<item row="13" column="2" colspan="2">
|
||||||
<widget class="QCheckBox" name="modelWizard_CB">
|
<widget class="QPushButton" name="libraryPathButton">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Use model wizard when creating a new model</string>
|
<string>Open Folder</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
@@ -1050,7 +1058,6 @@ Mode 4:
|
|||||||
</widget>
|
</widget>
|
||||||
<tabstops>
|
<tabstops>
|
||||||
<tabstop>tabWidget</tabstop>
|
<tabstop>tabWidget</tabstop>
|
||||||
<tabstop>profileNameLE</tabstop>
|
|
||||||
<tabstop>removeProfileButton</tabstop>
|
<tabstop>removeProfileButton</tabstop>
|
||||||
<tabstop>downloadVerCB</tabstop>
|
<tabstop>downloadVerCB</tabstop>
|
||||||
<tabstop>langCombo</tabstop>
|
<tabstop>langCombo</tabstop>
|
||||||
|
|||||||
@@ -22,7 +22,11 @@ radioData(new RadioData())
|
|||||||
ui->eepromFilename->hide();
|
ui->eepromFilename->hide();
|
||||||
ui->eepromLoad->hide();
|
ui->eepromLoad->hide();
|
||||||
}
|
}
|
||||||
QString backupPath = g.backupDir();
|
QString backupPath = g.profile[g.id()].pBackupDir();
|
||||||
|
if (backupPath.isEmpty()) {
|
||||||
|
backupPath=g.backupDir();
|
||||||
|
ui->backupBeforeWrite->setChecked(g.enableBackup() || g.profile[g.id()].penableBackup());
|
||||||
|
}
|
||||||
if (backupPath.isEmpty() || !QDir(backupPath).exists()) {
|
if (backupPath.isEmpty() || !QDir(backupPath).exists()) {
|
||||||
ui->backupBeforeWrite->setEnabled(false);
|
ui->backupBeforeWrite->setEnabled(false);
|
||||||
}
|
}
|
||||||
@@ -292,8 +296,13 @@ void FlashEEpromDialog::on_burnButton_clicked()
|
|||||||
|
|
||||||
// backup previous EEPROM if requested
|
// backup previous EEPROM if requested
|
||||||
QString backupFilename;
|
QString backupFilename;
|
||||||
|
QString backupPath;
|
||||||
if (ui->backupBeforeWrite->isChecked()) {
|
if (ui->backupBeforeWrite->isChecked()) {
|
||||||
backupFilename = g.backupDir() + "/backup-" + QDateTime().currentDateTime().toString("yyyy-MM-dd-HHmmss") + ".bin";
|
backupPath = g.profile[g.id()].pBackupDir();
|
||||||
|
if (backupPath.isEmpty()) {
|
||||||
|
backupPath=g.backupDir();
|
||||||
|
}
|
||||||
|
backupFilename = backupPath + "/backup-" + QDateTime().currentDateTime().toString("yyyy-MM-dd-HHmmss") + ".bin";
|
||||||
}
|
}
|
||||||
else if (ui->checkFirmwareCompatibility->isChecked()) {
|
else if (ui->checkFirmwareCompatibility->isChecked()) {
|
||||||
backupFilename = generateProcessUniqueTempFileName("eeprom.bin");
|
backupFilename = generateProcessUniqueTempFileName("eeprom.bin");
|
||||||
|
|||||||
@@ -46,7 +46,10 @@ fwName(g.profile[g.id()].fwName())
|
|||||||
ui->backupEEprom->setCheckState(g.backupOnFlash() ? Qt::Checked : Qt::Unchecked);
|
ui->backupEEprom->setCheckState(g.backupOnFlash() ? Qt::Checked : Qt::Unchecked);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString backupPath = g.backupDir();
|
QString backupPath = g.profile[g.id()].pBackupDir();
|
||||||
|
if (backupPath.isEmpty()) {
|
||||||
|
backupPath=g.backupDir();
|
||||||
|
}
|
||||||
if (backupPath.isEmpty() || !QDir(backupPath).exists()) {
|
if (backupPath.isEmpty() || !QDir(backupPath).exists()) {
|
||||||
ui->backupEEprom->setEnabled(false);
|
ui->backupEEprom->setEnabled(false);
|
||||||
}
|
}
|
||||||
@@ -278,8 +281,13 @@ void FlashFirmwareDialog::startFlash(const QString &filename)
|
|||||||
// backup if requested
|
// backup if requested
|
||||||
bool result = true;
|
bool result = true;
|
||||||
QString backupFilename;
|
QString backupFilename;
|
||||||
|
QString backupPath;
|
||||||
if (backup) {
|
if (backup) {
|
||||||
backupFilename = g.backupDir() + "/backup-" + QDateTime().currentDateTime().toString("yyyy-MM-dd-HHmmss") + ".bin";
|
backupPath = g.profile[g.id()].pBackupDir();
|
||||||
|
if (backupPath.isEmpty()) {
|
||||||
|
backupPath=g.backupDir();
|
||||||
|
}
|
||||||
|
backupFilename = backupPath + "/backup-" + QDateTime().currentDateTime().toString("yyyy-MM-dd-HHmmss") + ".bin";
|
||||||
result = readEeprom(backupFilename, progressDialog.progress());
|
result = readEeprom(backupFilename, progressDialog.progress());
|
||||||
sleep(2);
|
sleep(2);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -361,12 +361,31 @@ bool writeEeprom(const QString &filename, ProgressWidget *progress)
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if defined WIN32 || !defined __GNUC__
|
||||||
|
bool isRemovableMedia(const QString &vol )
|
||||||
|
{
|
||||||
|
char szDosDeviceName[MAX_PATH];
|
||||||
|
QString volume;
|
||||||
|
volume.append(vol);
|
||||||
|
UINT DriveType = GetDriveType( volume.replace("/","\\").toLatin1() );
|
||||||
|
if ( DriveType != DRIVE_REMOVABLE )
|
||||||
|
return false;
|
||||||
|
QueryDosDevice( volume.replace("/","").toLatin1(), szDosDeviceName, MAX_PATH );
|
||||||
|
if ( strstr( szDosDeviceName,"\\Floppy") != NULL ) { // its a floppy
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
QString findMassstoragePath(const QString &filename)
|
QString findMassstoragePath(const QString &filename)
|
||||||
{
|
{
|
||||||
QString temppath;
|
QString temppath;
|
||||||
QStringList drives;
|
QStringList drives;
|
||||||
QString eepromfile;
|
QString eepromfile;
|
||||||
QString fsname;
|
QString fsname;
|
||||||
|
static QStringList blacklist;
|
||||||
|
|
||||||
#if defined WIN32 || !defined __GNUC__
|
#if defined WIN32 || !defined __GNUC__
|
||||||
foreach(QFileInfo drive, QDir::drives()) {
|
foreach(QFileInfo drive, QDir::drives()) {
|
||||||
WCHAR szVolumeName[256] ;
|
WCHAR szVolumeName[256] ;
|
||||||
@@ -374,14 +393,20 @@ QString findMassstoragePath(const QString &filename)
|
|||||||
DWORD dwSerialNumber = 0;
|
DWORD dwSerialNumber = 0;
|
||||||
DWORD dwMaxFileNameLength=256;
|
DWORD dwMaxFileNameLength=256;
|
||||||
DWORD dwFileSystemFlags=0;
|
DWORD dwFileSystemFlags=0;
|
||||||
bool ret = GetVolumeInformationW( (WCHAR *) drive.absolutePath().utf16(),szVolumeName,256,&dwSerialNumber,&dwMaxFileNameLength,&dwFileSystemFlags,szFileSystemName,256);
|
if (!blacklist.contains(drive.absolutePath())) {
|
||||||
if (ret) {
|
if (!isRemovableMedia( drive.absolutePath() )) {
|
||||||
QString vName = QString::fromUtf16 ( (const ushort *) szVolumeName) ;
|
blacklist.append(drive.absolutePath());
|
||||||
temppath = drive.absolutePath();
|
} else {
|
||||||
eepromfile = temppath;
|
bool ret = GetVolumeInformationW( (WCHAR *) drive.absolutePath().utf16(),szVolumeName,256,&dwSerialNumber,&dwMaxFileNameLength,&dwFileSystemFlags,szFileSystemName,256);
|
||||||
eepromfile.append("/" + filename);
|
if (ret) {
|
||||||
if (QFile::exists(eepromfile)) {
|
QString vName = QString::fromUtf16 ( (const ushort *) szVolumeName) ;
|
||||||
return eepromfile;
|
temppath = drive.absolutePath();
|
||||||
|
eepromfile = temppath;
|
||||||
|
eepromfile.append("/" + filename);
|
||||||
|
if (QFile::exists(eepromfile)) {
|
||||||
|
return eepromfile;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user