diff options
author | Petr Mrázek <peterix@gmail.com> | 2017-05-21 22:24:06 +0200 |
---|---|---|
committer | Petr Mrázek <peterix@gmail.com> | 2017-05-21 22:24:06 +0200 |
commit | c329bc73c0c3830d2c2ec024c452b1a0e48e36a8 (patch) | |
tree | b7ea0b39845a2540cf76ab1c64eba290303ed918 /api | |
parent | d432d8ecfccab52a38a3c619bbad0078f50b7952 (diff) | |
download | MultiMC-c329bc73c0c3830d2c2ec024c452b1a0e48e36a8.tar MultiMC-c329bc73c0c3830d2c2ec024c452b1a0e48e36a8.tar.gz MultiMC-c329bc73c0c3830d2c2ec024c452b1a0e48e36a8.tar.lz MultiMC-c329bc73c0c3830d2c2ec024c452b1a0e48e36a8.tar.xz MultiMC-c329bc73c0c3830d2c2ec024c452b1a0e48e36a8.zip |
NOISSUE more compiler warning removal
Diffstat (limited to 'api')
-rw-r--r-- | api/logic/minecraft/ftb/LegacyFTBInstance.cpp | 7 | ||||
-rw-r--r-- | api/logic/minecraft/ftb/LegacyFTBInstance.h | 2 |
2 files changed, 3 insertions, 6 deletions
diff --git a/api/logic/minecraft/ftb/LegacyFTBInstance.cpp b/api/logic/minecraft/ftb/LegacyFTBInstance.cpp index a7091f1d..63412a33 100644 --- a/api/logic/minecraft/ftb/LegacyFTBInstance.cpp +++ b/api/logic/minecraft/ftb/LegacyFTBInstance.cpp @@ -12,13 +12,10 @@ QString LegacyFTBInstance::id() const return "FTB/" + BaseInstance::id(); } -void LegacyFTBInstance::copy(const QDir &newDir) +void LegacyFTBInstance::copy(SettingsObjectPtr newSettings, const QDir& newDir) { // set the target instance to be plain Legacy - INISettingsObject settings_obj(newDir.absoluteFilePath("instance.cfg")); - settings_obj.registerSetting("InstanceType", "Legacy"); - QString inst_type = settings_obj.get("InstanceType").toString(); - settings_obj.set("InstanceType", "Legacy"); + newSettings->set("InstanceType", "Legacy"); } QString LegacyFTBInstance::typeName() const diff --git a/api/logic/minecraft/ftb/LegacyFTBInstance.h b/api/logic/minecraft/ftb/LegacyFTBInstance.h index 8a97002a..2f2e34a2 100644 --- a/api/logic/minecraft/ftb/LegacyFTBInstance.h +++ b/api/logic/minecraft/ftb/LegacyFTBInstance.h @@ -8,7 +8,7 @@ class LegacyFTBInstance : public LegacyInstance public: explicit LegacyFTBInstance(SettingsObjectPtr globalSettings, SettingsObjectPtr settings, const QString &rootDir); QString id() const override; - void copy(const QDir &newDir) override; + void copy(SettingsObjectPtr newSettings, const QDir &newDir) override; QString typeName() const override; bool canExport() const override { |