Store the lastInputDir in settings

This commit is contained in:
Stanislav Ionascu 2020-02-22 09:47:48 +01:00
parent 6c077a43e7
commit ff68c7b4ab

@ -2708,6 +2708,7 @@ void TsMuxerWindow::writeSettings()
settings->setValue("hdmvPES", ui->checkBoxNewAudioPes->isChecked());
if (ui->checkBoxCrop->isEnabled())
settings->setValue("restoreCropEnabled", ui->checkBoxCrop->isChecked());
settings->setValue("inputDir", lastInputDir);
settings->setValue("outputDir", lastOutputDir);
settings->setValue("useBlankPL", ui->checkBoxBlankPL->isChecked());
settings->setValue("blankPLNum", ui->BlackplaylistCombo->value());
@ -2789,16 +2790,15 @@ bool TsMuxerWindow::readSettings()
bool TsMuxerWindow::readGeneralSettings(const QString &prefix)
{
settings->beginGroup(prefix);
QString outputDir = settings->value("outputDir").toString();
if (!outputDir.isEmpty())
lastOutputDir = outputDir;
else
if (!settings->contains("outputDir"))
{
settings->endGroup();
return false;
}
lastInputDir = settings->value("inputDir").toString();
lastOutputDir = settings->value("outputDir").toString();
// ui->checkBoxuseAsynIO->setChecked(settings->value("asyncIO").toBool());
ui->checkBoxSound->setChecked(settings->value("soundEnabled").toBool());
ui->checkBoxNewAudioPes->setChecked(settings->value("hdmvPES").toBool());