From d1594798e6e78bb329e744a72e92d3f292f38a20 Mon Sep 17 00:00:00 2001 From: Tannin Date: Fri, 1 Nov 2013 14:59:25 +0100 Subject: - added a new diagnosis to detect potential problems in regards to esp vs. asset ordering (not fully functional yet) - new plugin interfaces to the mod list - plugins can now query the origin (mod) of a esp/esm - bugfix: potential access to profile before one was activated - bugfix: regression in previous (not-yet-released) commit prevented changes to bsa list from being saved --- src/mainwindow.cpp | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) (limited to 'src/mainwindow.cpp') diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 967a3842..774c99f5 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -246,7 +246,7 @@ MainWindow::MainWindow(const QString &exeName, QSettings &initSettings, QWidget connect(ui->espFilterEdit, SIGNAL(textChanged(QString)), this, SLOT(espFilterChanged(QString))); connect(&m_PluginList, SIGNAL(saveTimer()), this, SLOT(savePluginList())); - connect(ui->bsaList, SIGNAL(itemsMoved()), this, SLOT(on_bsaList_itemMoved())); + connect(ui->bsaList, SIGNAL(itemsMoved()), this, SLOT(bsaList_itemMoved())); connect(ui->bsaWarning, SIGNAL(linkActivated(QString)), this, SLOT(linkClicked(QString))); @@ -1673,7 +1673,7 @@ void MainWindow::refreshSaveList() void MainWindow::refreshLists() { - if (m_DirectoryStructure->isPopulated()) { + if ((m_CurrentProfile != NULL) && m_DirectoryStructure->isPopulated()) { refreshESPList(); refreshBSAList(); } // no point in refreshing lists if no files have been added to the directory tree @@ -2104,6 +2104,11 @@ IPluginList *MainWindow::pluginList() return &m_PluginList; } +IModList *MainWindow::modList() +{ + return &m_ModList; +} + HANDLE MainWindow::startApplication(const QString &executable, const QStringList &args, const QString &cwd, const QString &profile) { QFileInfo binary; @@ -4650,13 +4655,19 @@ void MainWindow::on_bsaList_customContextMenuRequested(const QPoint &pos) menu.exec(ui->bsaList->mapToGlobal(pos)); } -void MainWindow::on_bsaList_itemMoved() +void MainWindow::bsaList_itemMoved() { saveArchiveList(); m_CheckBSATimer.start(500); } +void MainWindow::on_bsaList_itemChanged(QTreeWidgetItem*, int) +{ + saveArchiveList(); + m_CheckBSATimer.start(500); +} + void MainWindow::on_actionProblems_triggered() { // QString problemDescription; @@ -4836,3 +4847,4 @@ void MainWindow::on_showHiddenBox_toggled(bool checked) { m_DownloadManager.setShowHidden(checked); } + -- cgit v1.3.1