make tab index in sythesizer dialog persistent

This commit is contained in:
ws 2015-09-08 16:13:08 +02:00
parent b622c8fda5
commit 9878ef4680

View file

@ -79,14 +79,16 @@ SynthControl::SynthControl(QWidget* parent)
settings.beginGroup("SynthControl");
resize(settings.value("size", QSize(746, 268)).toSize());
move(settings.value("pos", QPoint(10, 10)).toPoint());
tabWidget->setCurrentIndex(settings.value("tab", 0).toInt());
settings.endGroup();
}
else
tabWidget->setCurrentIndex(0);
metronome->setDefaultAction(getAction("metronome"));
mgain->setValue(seq->metronomeGain());
updateGui();
tabWidget->setCurrentIndex(0);
storeButton->setEnabled(false);
recallButton->setEnabled(false);
changeTuningButton->setEnabled(false);
@ -402,6 +404,7 @@ void SynthControl::writeSettings()
settings.beginGroup("SynthControl");
settings.setValue("size", size());
settings.setValue("pos", pos());
settings.setValue("tab", tabWidget->currentIndex());
settings.endGroup();
}
}