Fixes #1200 - Needs tests!

This commit is contained in:
bsongis
2014-06-07 11:07:00 +02:00
parent 5de9f6c4a4
commit 93d6788605
21 changed files with 122 additions and 22 deletions
+16 -1
View File
@@ -51,7 +51,8 @@ GeneralEdit::GeneralEdit(RadioData &radioData, QWidget *parent) :
ui->chkSG->setValue(switchstate & 0x3);
switchstate >>= 2;
ui->chkSH->setValue(switchstate & 0x3);
} else {
}
else {
for (int i=0; pmsl[i]; i++) {
pmsl[i]->hide();
}
@@ -305,6 +306,14 @@ GeneralEdit::GeneralEdit(RadioData &radioData, QWidget *parent) :
ui->backlightColor2_label->hide();
}
if (IS_ARM(eepromInterface->getBoard())) {
ui->switchesDelay->setValue(10*g_eeGeneral.switchesDelay);
}
else {
ui->switchesDelay->hide();
ui->switchesDelayLabel->hide();
}
ga.sendPageView(getBoardName(GetCurrentFirmware()->getBoard()) + " GeneralEdit");
}
@@ -516,6 +525,12 @@ void GeneralEdit::on_backlightautoSB_editingFinished()
}
}
void GeneralEdit::on_switchesDelay_valueChanged()
{
g_eeGeneral.switchesDelay = ui->switchesDelay->value() / 10;
updateSettings();
}
void GeneralEdit::on_backlightColor_SL_valueChanged()
{
g_eeGeneral.backlightColor = ui->backlightColor_SL->value();