From 2b24fe09c50adc181b4a37a5b4697187549bb373 Mon Sep 17 00:00:00 2001 From: sledgehammer999 Date: Sun, 1 Feb 2015 01:37:53 +0200 Subject: [PATCH] Save the new save path first in the history. Closes #2382. --- src/addnewtorrentdialog.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/addnewtorrentdialog.cpp b/src/addnewtorrentdialog.cpp index 7549b9224..19f062167 100644 --- a/src/addnewtorrentdialog.cpp +++ b/src/addnewtorrentdialog.cpp @@ -262,10 +262,10 @@ void AddNewTorrentDialog::saveSavePathHistory() const history_dirs << QDir(dir); if (!history_dirs.contains(selected_save_path)) { // Add save path to history - history << selected_save_path.absolutePath(); + history.push_front(selected_save_path.absolutePath()); // Limit list size if (history.size() > 8) - history.removeFirst(); + history.pop_back(); // Save history pref->setAddNewTorrentDialogPathHistory(history); }