summaryrefslogtreecommitdiff
path: root/src/organizercore.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/organizercore.cpp')
-rw-r--r--src/organizercore.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/organizercore.cpp b/src/organizercore.cpp
index 4dceefbf..a668de6b 100644
--- a/src/organizercore.cpp
+++ b/src/organizercore.cpp
@@ -988,6 +988,13 @@ MOBase::IModInterface *OrganizerCore::installMod(const QString &fileName,
return nullptr;
}
+ if (m_InstallationManager.isRunning()) {
+ QMessageBox::information(
+ qApp->activeWindow(), tr("Installation cancelled"),
+ tr("Another installation is currently in progress."), QMessageBox::Ok);
+ return nullptr;
+ }
+
bool hasIniTweaks = false;
GuessedValue<QString> modName;
if (!initModName.isEmpty()) {
@@ -1029,6 +1036,13 @@ MOBase::IModInterface *OrganizerCore::installMod(const QString &fileName,
void OrganizerCore::installDownload(int index)
{
+ if (m_InstallationManager.isRunning()) {
+ QMessageBox::information(
+ qApp->activeWindow(), tr("Installation cancelled"),
+ tr("Another installation is currently in progress."), QMessageBox::Ok);
+ return;
+ }
+
try {
QString fileName = m_DownloadManager.getFilePath(index);
QString gameName = m_DownloadManager.getGameName(index);