summaryrefslogtreecommitdiff
path: root/src/mainwindow.cpp
diff options
context:
space:
mode:
authorMikaël Capelle <capelle.mikael@gmail.com>2020-12-31 23:44:45 +0100
committerMikaël Capelle <capelle.mikael@gmail.com>2021-01-02 15:38:18 +0100
commit33860662c1cd5d39cf51d411870a84b9081c8427 (patch)
treea2e3f35dfa90384382143bb353be7f6abb5bca9f /src/mainwindow.cpp
parent87dac464d9ec488737b16839b0f06586eadb837e (diff)
Move sort plugins handler to PluginListView.
Diffstat (limited to 'src/mainwindow.cpp')
-rw-r--r--src/mainwindow.cpp43
1 files changed, 0 insertions, 43 deletions
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index 55019a44..2068b476 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -254,7 +254,6 @@ MainWindow::MainWindow(Settings &settings
, m_CategoryFactory(CategoryFactory::instance())
, m_OrganizerCore(organizerCore)
, m_PluginContainer(pluginContainer)
- , m_DidUpdateMasterList(false)
, m_ArchiveListWriter(std::bind(&MainWindow::saveArchiveList, this))
, m_LinkToolbar(nullptr)
, m_LinkDesktop(nullptr)
@@ -3304,48 +3303,6 @@ void MainWindow::on_showHiddenBox_toggled(bool checked)
m_OrganizerCore.downloadManager()->setShowHidden(checked);
}
-void MainWindow::on_bossButton_clicked()
-{
- const bool offline = m_OrganizerCore.settings().network().offlineMode();
-
- auto r = QMessageBox::No;
-
- if (offline) {
- r = QMessageBox::question(
- this, tr("Sorting plugins"),
- tr("Are you sure you want to sort your plugins list?") + "\r\n\r\n" +
- tr("Note: You are currently in offline mode and LOOT will not update the master list."),
- QMessageBox::Yes | QMessageBox::No);
- } else {
- r = QMessageBox::question(
- this, tr("Sorting plugins"),
- tr("Are you sure you want to sort your plugins list?"),
- QMessageBox::Yes | QMessageBox::No);
- }
-
- if (r != QMessageBox::Yes) {
- return;
- }
-
- m_OrganizerCore.savePluginList();
-
- setEnabled(false);
- ON_BLOCK_EXIT([&] () { setEnabled(true); });
-
- // don't try to update the master list in offline mode
- const bool didUpdateMasterList = offline ? true : m_DidUpdateMasterList;
-
- if (runLoot(this, m_OrganizerCore, didUpdateMasterList)) {
- // don't assume the master list was updated in offline mode
- if (!offline) {
- m_DidUpdateMasterList = true;
- }
-
- m_OrganizerCore.refreshESPList(false);
- m_OrganizerCore.savePluginList();
- }
-}
-
const char *MainWindow::PATTERN_BACKUP_GLOB = ".????_??_??_??_??_??";
const char *MainWindow::PATTERN_BACKUP_REGEX = "\\.(\\d\\d\\d\\d_\\d\\d_\\d\\d_\\d\\d_\\d\\d_\\d\\d)";
const char *MainWindow::PATTERN_BACKUP_DATE = "yyyy_MM_dd_hh_mm_ss";