diff options
author | Trial97 <alexandru.tripon97@gmail.com> | 2023-07-17 17:42:15 +0300 |
---|---|---|
committer | Trial97 <alexandru.tripon97@gmail.com> | 2023-07-17 17:52:00 +0300 |
commit | b0940d696baa24ddcf29a5d3393196c1047dcd3f (patch) | |
tree | 7a4af66640c9b3edab45ef808d1f256cd57ea17b /launcher/ui/dialogs/ExportInstanceDialog.cpp | |
parent | fe73d696cb714d724948176f0bfbb356412b0f11 (diff) | |
download | PrismLauncher-b0940d696baa24ddcf29a5d3393196c1047dcd3f.tar.gz PrismLauncher-b0940d696baa24ddcf29a5d3393196c1047dcd3f.tar.bz2 PrismLauncher-b0940d696baa24ddcf29a5d3393196c1047dcd3f.zip |
Added QFutureWatcher
Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
abort
forgot
Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
Diffstat (limited to 'launcher/ui/dialogs/ExportInstanceDialog.cpp')
-rw-r--r-- | launcher/ui/dialogs/ExportInstanceDialog.cpp | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/launcher/ui/dialogs/ExportInstanceDialog.cpp b/launcher/ui/dialogs/ExportInstanceDialog.cpp index 1a3f8cd4..d1a69b93 100644 --- a/launcher/ui/dialogs/ExportInstanceDialog.cpp +++ b/launcher/ui/dialogs/ExportInstanceDialog.cpp @@ -146,11 +146,8 @@ void ExportInstanceDialog::doExport() auto task = makeShared<MMCZip::ExportToZipTask>(output, m_instance->instanceRoot(), files, "", true); - connect(task.get(), &Task::failed, this, [this, output](QString reason) { - CustomMessageBox::selectable(this, tr("Error"), reason, QMessageBox::Critical)->show(); - QFile::remove(output); - }); - connect(task.get(), &Task::aborted, this, [output] { QFile::remove(output); }); + connect(task.get(), &Task::failed, this, + [this, output](QString reason) { CustomMessageBox::selectable(this, tr("Error"), reason, QMessageBox::Critical)->show(); }); connect(task.get(), &Task::finished, this, [task] { task->deleteLater(); }); ProgressDialog progress(this); |