aboutsummaryrefslogtreecommitdiff
path: root/launcher/Application.cpp
diff options
context:
space:
mode:
authorSefa Eyeoglu <contact@scrumplex.net>2022-06-13 23:10:35 +0200
committerGitHub <noreply@github.com>2022-06-13 23:10:35 +0200
commit349fc4143d4c83c50aa6340bbe7dc537a6fbf949 (patch)
treee462fdf55cf6614fa222a8308d05ef3943cc215b /launcher/Application.cpp
parentcb258146c4f66a1e3ad8f9262030900737d20101 (diff)
parent4be9e6a0bc0a4ac6b47ead7008b8a6a811c63b4d (diff)
downloadPrismLauncher-349fc4143d4c83c50aa6340bbe7dc537a6fbf949.tar.gz
PrismLauncher-349fc4143d4c83c50aa6340bbe7dc537a6fbf949.tar.bz2
PrismLauncher-349fc4143d4c83c50aa6340bbe7dc537a6fbf949.zip
Merge pull request #714 from Scrumplex/fix-tests
Fix mod metadata tests
Diffstat (limited to 'launcher/Application.cpp')
-rw-r--r--launcher/Application.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/launcher/Application.cpp b/launcher/Application.cpp
index 4e0393c0..ab3110a3 100644
--- a/launcher/Application.cpp
+++ b/launcher/Application.cpp
@@ -154,6 +154,7 @@ void appDebugOutput(QtMsgType type, const QMessageLogContext &context, const QSt
fflush(stderr);
}
+#ifdef LAUNCHER_WITH_UPDATER
QString getIdealPlatform(QString currentPlatform) {
auto info = Sys::getKernelInfo();
switch(info.kernelType) {
@@ -192,6 +193,7 @@ QString getIdealPlatform(QString currentPlatform) {
}
return currentPlatform;
}
+#endif
}
@@ -754,6 +756,7 @@ Application::Application(int &argc, char **argv) : QApplication(argc, argv)
qDebug() << "<> Translations loaded.";
}
+#ifdef LAUNCHER_WITH_UPDATER
// initialize the updater
if(BuildConfig.UPDATER_ENABLED)
{
@@ -763,6 +766,7 @@ Application::Application(int &argc, char **argv) : QApplication(argc, argv)
m_updateChecker.reset(new UpdateChecker(m_network, channelUrl, BuildConfig.VERSION_CHANNEL, BuildConfig.VERSION_BUILD));
qDebug() << "<> Updater started.";
}
+#endif
// Instance icons
{
@@ -1408,7 +1412,9 @@ MainWindow* Application::showMainWindow(bool minimized)
}
m_mainWindow->checkInstancePathForProblems();
+#ifdef LAUNCHER_WITH_UPDATER
connect(this, &Application::updateAllowedChanged, m_mainWindow, &MainWindow::updatesAllowedChanged);
+#endif
connect(m_mainWindow, &MainWindow::isClosing, this, &Application::on_windowClose);
m_openWindows++;
}