aboutsummaryrefslogtreecommitdiff
path: root/launcher/ui/dialogs/ModUpdateDialog.cpp
diff options
context:
space:
mode:
authorSefa Eyeoglu <contact@scrumplex.net>2022-08-28 16:52:53 +0200
committerGitHub <noreply@github.com>2022-08-28 16:52:53 +0200
commitf371ec210c091b9ebc91930be74752383cb941c6 (patch)
treef3b13e1015285e76145552d21503ff641bf4ce11 /launcher/ui/dialogs/ModUpdateDialog.cpp
parentafcd669d2f6934c2b6076939d7665f791d495994 (diff)
parent0b81b283bfdd16b409127f22eac7b51ce0142929 (diff)
downloadPrismLauncher-f371ec210c091b9ebc91930be74752383cb941c6.tar.gz
PrismLauncher-f371ec210c091b9ebc91930be74752383cb941c6.tar.bz2
PrismLauncher-f371ec210c091b9ebc91930be74752383cb941c6.zip
Merge pull request #1052 from flowln/resource_model
Diffstat (limited to 'launcher/ui/dialogs/ModUpdateDialog.cpp')
-rw-r--r--launcher/ui/dialogs/ModUpdateDialog.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/launcher/ui/dialogs/ModUpdateDialog.cpp b/launcher/ui/dialogs/ModUpdateDialog.cpp
index 936fd99d..4171586e 100644
--- a/launcher/ui/dialogs/ModUpdateDialog.cpp
+++ b/launcher/ui/dialogs/ModUpdateDialog.cpp
@@ -36,7 +36,7 @@ static ModAPI::ModLoaderTypes mcLoaders(BaseInstance* inst)
ModUpdateDialog::ModUpdateDialog(QWidget* parent,
BaseInstance* instance,
const std::shared_ptr<ModFolderModel> mods,
- QList<Mod::Ptr>& search_for)
+ QList<Mod*>& search_for)
: ReviewMessageBox(parent, tr("Confirm mods to update"), "")
, m_parent(parent)
, m_mod_model(mods)
@@ -226,9 +226,8 @@ auto ModUpdateDialog::ensureMetadata() -> bool
};
for (auto candidate : m_candidates) {
- auto* candidate_ptr = candidate.get();
if (candidate->status() != ModStatus::NoMetadata) {
- onMetadataEnsured(candidate_ptr);
+ onMetadataEnsured(candidate);
continue;
}
@@ -236,7 +235,7 @@ auto ModUpdateDialog::ensureMetadata() -> bool
continue;
if (confirm_rest) {
- addToTmp(candidate_ptr, provider_rest);
+ addToTmp(candidate, provider_rest);
should_try_others.insert(candidate->internal_id(), try_others_rest);
continue;
}
@@ -261,7 +260,7 @@ auto ModUpdateDialog::ensureMetadata() -> bool
should_try_others.insert(candidate->internal_id(), response.try_others);
if (confirmed)
- addToTmp(candidate_ptr, response.chosen);
+ addToTmp(candidate, response.chosen);
}
if (!modrinth_tmp.empty()) {