aboutsummaryrefslogtreecommitdiff
path: root/launcher/ui/pages
diff options
context:
space:
mode:
authorflow <thiagodonato300@gmail.com>2022-05-01 11:08:00 -0300
committerflow <flowlnlnln@gmail.com>2022-05-21 08:36:36 -0300
commit166f8727121399f7604d25580ced39472e9a3034 (patch)
treea7172abed06076190f0befada203eb7ed386bf04 /launcher/ui/pages
parent8f2c485c926e53f8b31f420f3d5caec090982498 (diff)
downloadPrismLauncher-166f8727121399f7604d25580ced39472e9a3034.tar.gz
PrismLauncher-166f8727121399f7604d25580ced39472e9a3034.tar.bz2
PrismLauncher-166f8727121399f7604d25580ced39472e9a3034.zip
fix: various issues with ProgressDialog and SequentialTasks
- Fix aborting sequential tasks - Fix displaying wrong number of tasks concluded - Fix text cutting when the URL is too big
Diffstat (limited to 'launcher/ui/pages')
-rw-r--r--launcher/ui/pages/instance/ModFolderPage.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/launcher/ui/pages/instance/ModFolderPage.cpp b/launcher/ui/pages/instance/ModFolderPage.cpp
index 8113fe85..cba25564 100644
--- a/launcher/ui/pages/instance/ModFolderPage.cpp
+++ b/launcher/ui/pages/instance/ModFolderPage.cpp
@@ -402,6 +402,10 @@ void ModFolderPage::on_actionInstall_mods_triggered()
CustomMessageBox::selectable(this, tr("Error"), reason, QMessageBox::Critical)->show();
tasks->deleteLater();
});
+ connect(tasks, &Task::aborted, [this, tasks]() {
+ CustomMessageBox::selectable(this, tr("Aborted"), tr("Download stopped by user."), QMessageBox::Information)->show();
+ tasks->deleteLater();
+ });
connect(tasks, &Task::succeeded, [this, tasks]() {
QStringList warnings = tasks->warnings();
if (warnings.count()) { CustomMessageBox::selectable(this, tr("Warnings"), warnings.join('\n'), QMessageBox::Warning)->show(); }
@@ -411,6 +415,7 @@ void ModFolderPage::on_actionInstall_mods_triggered()
for (auto task : mdownload.getTasks()) {
tasks->addTask(task);
}
+
ProgressDialog loadDialog(this);
loadDialog.setSkipButton(true, tr("Abort"));
loadDialog.execWithTask(tasks);