From 89249c140ffc933a54c17f6cbe30fef667a1d4a7 Mon Sep 17 00:00:00 2001 From: Christophe Dumez Date: Fri, 6 Jul 2012 20:12:39 +0300 Subject: [PATCH] Fix "Set as default save path" checkbox in torrent addition dialog --- src/addnewtorrentdialog.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/addnewtorrentdialog.cpp b/src/addnewtorrentdialog.cpp index 58b65ca4b..a93ce4875 100644 --- a/src/addnewtorrentdialog.cpp +++ b/src/addnewtorrentdialog.cpp @@ -369,6 +369,7 @@ void AddNewTorrentDialog::onSavePathChanged(int index) connect(ui->save_path_combo, SIGNAL(currentIndexChanged(int)), SLOT(onSavePathChanged(int))); } // Toggle default save path setting checkbox visibility + ui->default_save_path_cb->setChecked(false); ui->default_save_path_cb->setVisible(QDir(ui->save_path_combo->itemData(ui->save_path_combo->currentIndex()).toString()) != defaultSaveDir); relayout(); // Remember index @@ -593,6 +594,6 @@ void AddNewTorrentDialog::on_buttonBox_accepted() saveSavePathHistory(); // Save settings pref.useAdditionDialog(!ui->never_show_cb->isChecked()); - if (ui->default_save_path_cb->isVisible() && ui->default_save_path_cb->isChecked()) + if (ui->default_save_path_cb->isChecked()) pref.setSavePath(ui->save_path_combo->itemData(ui->save_path_combo->currentIndex()).toString()); }