From db0347212a509b9ceef1cede61a4afd7d2253014 Mon Sep 17 00:00:00 2001 From: Tannin Date: Fri, 22 Nov 2013 17:45:34 +0100 Subject: - bugfix: installFile for mods was not a relative path if the downloads directory was non-default - bugfix: crash after removing the last profile in the list (ordered alphabetically) - improved subdirs ordering to ensure pythonrunner is compiled before pythonproxy - translation files for plugins are now generated - set some texts as un-translatable where it made no sense - staging script now re-builds MO completely before packaging - updated qt libraries for packaging to 4.8.5 - added python to the package --- src/mainwindow.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/mainwindow.cpp') diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index a8026b68..31ee1ae7 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -223,6 +223,7 @@ MainWindow::MainWindow(const QString &exeName, QSettings &initSettings, QWidget NexusInterface::instance()->setNMMVersion(m_Settings.getNMMVersion()); m_InstallationManager.setModsDirectory(m_Settings.getModDirectory()); + m_InstallationManager.setDownloadDirectory(m_Settings.getDownloadDirectory()); updateDownloadListDelegate(); @@ -1435,6 +1436,12 @@ void MainWindow::on_profileBox_currentIndexChanged(int index) saveCurrentLists(); } + // ensure the new index is valid + if (index < 0 || index >= ui->profileBox->count()) { + qDebug("invalid profile index, using last profile"); + ui->profileBox->setCurrentIndex(ui->profileBox->count() - 1); + } + if (ui->profileBox->currentIndex() == 0) { ProfilesDialog(m_GamePath).exec(); while (!refreshProfiles()) { @@ -3909,6 +3916,7 @@ void MainWindow::on_actionSettings_triggered() bool proxy = m_Settings.useProxy(); m_Settings.query(this); m_InstallationManager.setModsDirectory(m_Settings.getModDirectory()); + m_InstallationManager.setDownloadDirectory(m_Settings.getDownloadDirectory()); fixCategories(); refreshFilters(); if (QDir::fromNativeSeparators(m_DownloadManager.getOutputDirectory()) != QDir::fromNativeSeparators(m_Settings.getDownloadDirectory())) { -- cgit v1.3.1