aboutsummaryrefslogtreecommitdiff
path: root/launcher/modplatform
diff options
context:
space:
mode:
authorflow <flowlnlnln@gmail.com>2022-11-01 19:48:26 -0300
committerflow <flowlnlnln@gmail.com>2022-11-01 19:48:26 -0300
commit7956e6f04e32448b0043a49ff08873e117ba0a0b (patch)
treea451fa409e400f3c9cc27715df3be7abc2ca043e /launcher/modplatform
parentf6a3fa55b1fb4b10780065fd8e1df722cd40efd8 (diff)
downloadPrismLauncher-7956e6f04e32448b0043a49ff08873e117ba0a0b.tar.gz
PrismLauncher-7956e6f04e32448b0043a49ff08873e117ba0a0b.tar.bz2
PrismLauncher-7956e6f04e32448b0043a49ff08873e117ba0a0b.zip
fix: don't use forward-declared Ptr types in meta/
This would cause ODR violations when those headers were included in other places that also included stuff like "Version.h" (note the "meta/Version.h"), which can cause problems, especially in LTO. Signed-off-by: flow <flowlnlnln@gmail.com>
Diffstat (limited to 'launcher/modplatform')
-rw-r--r--launcher/modplatform/atlauncher/ATLPackInstallTask.cpp4
-rw-r--r--launcher/modplatform/atlauncher/ATLPackInstallTask.h6
2 files changed, 5 insertions, 5 deletions
diff --git a/launcher/modplatform/atlauncher/ATLPackInstallTask.cpp b/launcher/modplatform/atlauncher/ATLPackInstallTask.cpp
index 68d75943..291ad916 100644
--- a/launcher/modplatform/atlauncher/ATLPackInstallTask.cpp
+++ b/launcher/modplatform/atlauncher/ATLPackInstallTask.cpp
@@ -58,7 +58,7 @@
namespace ATLauncher {
-static Meta::VersionPtr getComponentVersion(const QString& uid, const QString& version);
+static Meta::Version::Ptr getComponentVersion(const QString& uid, const QString& version);
PackInstallTask::PackInstallTask(UserInteractionSupport *support, QString packName, QString version, InstallMode installMode)
{
@@ -1037,7 +1037,7 @@ void PackInstallTask::install()
emitSucceeded();
}
-static Meta::VersionPtr getComponentVersion(const QString& uid, const QString& version)
+static Meta::Version::Ptr getComponentVersion(const QString& uid, const QString& version)
{
auto vlist = APPLICATION->metadataIndex()->get(uid);
if (!vlist)
diff --git a/launcher/modplatform/atlauncher/ATLPackInstallTask.h b/launcher/modplatform/atlauncher/ATLPackInstallTask.h
index 78cd87fb..90e25ae2 100644
--- a/launcher/modplatform/atlauncher/ATLPackInstallTask.h
+++ b/launcher/modplatform/atlauncher/ATLPackInstallTask.h
@@ -68,7 +68,7 @@ public:
* Requests a user interaction to select a component version from a given version list
* and constrained to a given Minecraft version.
*/
- virtual QString chooseVersion(Meta::VersionListPtr vlist, QString minecraftVersion) = 0;
+ virtual QString chooseVersion(Meta::VersionList::Ptr vlist, QString minecraftVersion) = 0;
/**
* Requests a user interaction to display a message.
@@ -137,8 +137,8 @@ private:
QString archivePath;
QStringList jarmods;
- Meta::VersionPtr minecraftVersion;
- QMap<QString, Meta::VersionPtr> componentsToInstall;
+ Meta::Version::Ptr minecraftVersion;
+ QMap<QString, Meta::Version::Ptr> componentsToInstall;
QFuture<std::optional<QStringList>> m_extractFuture;
QFutureWatcher<std::optional<QStringList>> m_extractFutureWatcher;