diff options
author | swirl <swurl@swurl.xyz> | 2022-02-03 14:14:12 -0500 |
---|---|---|
committer | swirl <swurl@swurl.xyz> | 2022-02-03 14:14:12 -0500 |
commit | 076efc4cb2586edbc11868bd93f48cfe03eb5a6d (patch) | |
tree | c525883696e42d8b3e2253e1b2eb08d43883abc6 /launcher/ui | |
parent | 2c62a34c2f47961e343b8aae37cd76ed7520593e (diff) | |
parent | c4cb7ddc4f9c06006d585ba7ff7405ac0cfdbb3c (diff) | |
download | PrismLauncher-076efc4cb2586edbc11868bd93f48cfe03eb5a6d.tar.gz PrismLauncher-076efc4cb2586edbc11868bd93f48cfe03eb5a6d.tar.bz2 PrismLauncher-076efc4cb2586edbc11868bd93f48cfe03eb5a6d.zip |
Merge branch 'update-quazip' of git://github.com/Scrumplex/PolyMC into develop
Diffstat (limited to 'launcher/ui')
-rw-r--r-- | launcher/ui/dialogs/ExportInstanceDialog.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/launcher/ui/dialogs/ExportInstanceDialog.cpp b/launcher/ui/dialogs/ExportInstanceDialog.cpp index 1a164875..f3bf7abe 100644 --- a/launcher/ui/dialogs/ExportInstanceDialog.cpp +++ b/launcher/ui/dialogs/ExportInstanceDialog.cpp @@ -403,7 +403,13 @@ bool ExportInstanceDialog::doExport() auto & blocked = proxyModel->blockedPaths(); using std::placeholders::_1; - if (!JlCompress::compressDir(output, m_instance->instanceRoot(), name, std::bind(&SeparatorPrefixTree<'/'>::covers, blocked, _1))) + auto files = QFileInfoList(); + if (!MMCZip::collectFileListRecursively(m_instance->instanceRoot(), nullptr, &files, + std::bind(&SeparatorPrefixTree<'/'>::covers, blocked, _1))) { + QMessageBox::warning(this, tr("Error"), tr("Unable to export instance")); + return false; + } + if (!MMCZip::compressDirFiles(output, m_instance->instanceRoot(), files)) { QMessageBox::warning(this, tr("Error"), tr("Unable to export instance")); return false; |