From 8d73ab65b20556dde1f973dccd56aa50597eb1fa Mon Sep 17 00:00:00 2001 From: Chocobo1 Date: Sat, 9 Jul 2022 02:02:15 +0800 Subject: [PATCH] Don't needlessly hide Options dialog The dialog should only close after all operations are done, not before. --- src/gui/optionsdialog.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/gui/optionsdialog.cpp b/src/gui/optionsdialog.cpp index 876792958..804e0a7a9 100644 --- a/src/gui/optionsdialog.cpp +++ b/src/gui/optionsdialog.cpp @@ -650,8 +650,6 @@ void OptionsDialog::saveOptions() auto *pref = Preferences::instance(); auto *session = BitTorrent::Session::instance(); - m_applyButton->setEnabled(false); - // Load the translation QString locale = getLocale(); if (pref->getLocale() != locale) @@ -1419,8 +1417,8 @@ void OptionsDialog::on_buttonBox_accepted() m_ui->tabSelection->setCurrentRow(TAB_WEBUI); return; } + m_applyButton->setEnabled(false); - this->hide(); saveOptions(); } @@ -1444,6 +1442,8 @@ void OptionsDialog::applySettings() m_ui->tabSelection->setCurrentRow(TAB_WEBUI); return; } + + m_applyButton->setEnabled(false); saveOptions(); }