aboutsummaryrefslogtreecommitdiff
path: root/launcher
diff options
context:
space:
mode:
authorflow <flowlnlnln@gmail.com>2022-12-07 18:05:46 -0300
committerflow <flowlnlnln@gmail.com>2022-12-07 18:05:46 -0300
commit34230bfcf415b4ad314d2534e09b40058ef9eaa2 (patch)
tree940dbb1202d7c813f055c6f23376836253853895 /launcher
parent6f50809457a2c974f0f8f15f5158cac7347e18d2 (diff)
downloadPrismLauncher-34230bfcf415b4ad314d2534e09b40058ef9eaa2.tar.gz
PrismLauncher-34230bfcf415b4ad314d2534e09b40058ef9eaa2.tar.bz2
PrismLauncher-34230bfcf415b4ad314d2534e09b40058ef9eaa2.zip
fix: don't try updating Flame instance names when updating versions
Since the exact version string is only available in the manifest, there's no easy way of getting it before commiting to the update, so there's not much of a good way of showing the updated name in the UI, and using the displayName is weird and gives some buggy behavior. We may want to re-enable it in the future if we find a reliable way of showing the correct info on the UI before starting the update. Signed-off-by: flow <flowlnlnln@gmail.com>
Diffstat (limited to 'launcher')
-rw-r--r--launcher/modplatform/flame/FlameInstanceCreationTask.cpp8
-rw-r--r--launcher/ui/pages/instance/ManagedPackPage.cpp5
2 files changed, 1 insertions, 12 deletions
diff --git a/launcher/modplatform/flame/FlameInstanceCreationTask.cpp b/launcher/modplatform/flame/FlameInstanceCreationTask.cpp
index 1e76f252..eae66ec7 100644
--- a/launcher/modplatform/flame/FlameInstanceCreationTask.cpp
+++ b/launcher/modplatform/flame/FlameInstanceCreationTask.cpp
@@ -385,14 +385,6 @@ bool FlameCreationTask::createInstance()
setAbortable(false);
auto inst = m_instance.value();
- // Only change the name if it didn't use a custom name, so that the previous custom name
- // is preserved, but if we're using the original one, we update the version string.
- // NOTE: This needs to come before the copyManagedPack call!
- if (inst->name().contains(inst->getManagedPackVersionName())) {
- if (askForChangingInstanceName(m_parent, inst->name(), instance.name()) == InstanceNameChange::ShouldChange)
- inst->setName(instance.name());
- }
-
inst->copyManagedPack(instance);
}
diff --git a/launcher/ui/pages/instance/ManagedPackPage.cpp b/launcher/ui/pages/instance/ManagedPackPage.cpp
index c70d70ab..7a0d234c 100644
--- a/launcher/ui/pages/instance/ManagedPackPage.cpp
+++ b/launcher/ui/pages/instance/ManagedPackPage.cpp
@@ -418,10 +418,7 @@ void FlameManagedPackPage::update()
auto extracted = new InstanceImportTask(version.downloadUrl, this, std::move(extra_info));
- InstanceName inst_name(m_inst->getManagedPackName(), version.version);
- inst_name.setName(m_inst->name().replace(m_inst->getManagedPackVersionName(), version.version));
- extracted->setName(inst_name);
-
+ extracted->setName(m_inst->name());
extracted->setGroup(APPLICATION->instances()->getInstanceGroup(m_inst->id()));
extracted->setIcon(m_inst->iconKey());
extracted->setConfirmUpdate(false);