mirror of https://github.com/EspoTek/Labrador.git
Android build 20210328 (#166)
* Remove saving preference for the Range Dialog that has not been added to Android yet.
This commit is contained in:
parent
d9f05e3ec5
commit
a098e6d7fb
|
@ -1240,12 +1240,14 @@ void MainWindow::readSettingsFile(){
|
||||||
double calibrate_gain_ch1 = settings->value("CalibrateGainCH1", R4/(R3+R4)).toDouble();
|
double calibrate_gain_ch1 = settings->value("CalibrateGainCH1", R4/(R3+R4)).toDouble();
|
||||||
double calibrate_gain_ch2 = settings->value("CalibrateGainCH2", R4/(R3+R4)).toDouble();
|
double calibrate_gain_ch2 = settings->value("CalibrateGainCH2", R4/(R3+R4)).toDouble();
|
||||||
psu_voltage_calibration_offset = settings->value("CalibratePsu", 0).toDouble();
|
psu_voltage_calibration_offset = settings->value("CalibratePsu", 0).toDouble();
|
||||||
|
#ifndef PLATFORM_ANDROID
|
||||||
if (settings->value("ShowRangeDialog").toBool())
|
if (settings->value("ShowRangeDialog").toBool())
|
||||||
{
|
{
|
||||||
qDebug() << "ShowRangeDialog setting true";
|
qDebug() << "ShowRangeDialog setting true";
|
||||||
ui->actionShow_Range_Dialog_on_Main_Page->setChecked(true);
|
ui->actionShow_Range_Dialog_on_Main_Page->setChecked(true);
|
||||||
on_actionShow_Range_Dialog_on_Main_Page_triggered(true);
|
on_actionShow_Range_Dialog_on_Main_Page_triggered(true);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
daq_num_to_average = settings->value("daq_defaultAverage", 1).toInt();
|
daq_num_to_average = settings->value("daq_defaultAverage", 1).toInt();
|
||||||
daq_max_file_size = settings->value("daq_defaultFileSize", 2048000000).toULongLong();
|
daq_max_file_size = settings->value("daq_defaultFileSize", 2048000000).toULongLong();
|
||||||
|
@ -2382,7 +2384,9 @@ void MainWindow::on_actionShow_Range_Dialog_on_Main_Page_triggered(bool checked)
|
||||||
qDebug() << "on_actionShow_Range_Dialog_on_Main_Page_triggered" << checked;
|
qDebug() << "on_actionShow_Range_Dialog_on_Main_Page_triggered" << checked;
|
||||||
if (checked)
|
if (checked)
|
||||||
{
|
{
|
||||||
|
#ifndef PLATFORM_ANDROID
|
||||||
settings->setValue("ShowRangeDialog", true);
|
settings->setValue("ShowRangeDialog", true);
|
||||||
|
#endif
|
||||||
scopeRangeSwitch = new scopeRangeEnterDialog(nullptr, false, ui->controller_iso->display.topRange, ui->controller_iso->display.botRange, ui->controller_iso->display.window, ui->controller_iso->display.delay);
|
scopeRangeSwitch = new scopeRangeEnterDialog(nullptr, false, ui->controller_iso->display.topRange, ui->controller_iso->display.botRange, ui->controller_iso->display.window, ui->controller_iso->display.delay);
|
||||||
scopeRangeSwitch->setWindowFlags(Qt::Widget);
|
scopeRangeSwitch->setWindowFlags(Qt::Widget);
|
||||||
#ifndef PLATFORM_ANDROID
|
#ifndef PLATFORM_ANDROID
|
||||||
|
@ -2400,7 +2404,9 @@ void MainWindow::on_actionShow_Range_Dialog_on_Main_Page_triggered(bool checked)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
#ifndef PLATFORM_ANDROID
|
||||||
settings->setValue("ShowRangeDialog", false);
|
settings->setValue("ShowRangeDialog", false);
|
||||||
|
#endif
|
||||||
delete scopeRangeSwitch;
|
delete scopeRangeSwitch;
|
||||||
scopeRangeSwitch = nullptr;
|
scopeRangeSwitch = nullptr;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue