mirror of
https://gitlab.com/kelteseth/ScreenPlay.git
synced 2024-11-07 03:22:33 +01:00
Simplify version check
This commit is contained in:
parent
fa3d21df27
commit
1456610bd4
@ -59,7 +59,7 @@ App::App()
|
|||||||
// Init after we have the paths from settings
|
// Init after we have the paths from settings
|
||||||
m_installedListModel->init();
|
m_installedListModel->init();
|
||||||
|
|
||||||
#if QT_VERSION > QT_VERSION_CHECK(5, 14, 0)
|
#if QT_VERSION >= QT_VERSION_CHECK(5, 14, 0)
|
||||||
// Set visible if the -silent parameter was not set
|
// Set visible if the -silent parameter was not set
|
||||||
if (QGuiApplication::instance()->arguments().contains("-silent")) {
|
if (QGuiApplication::instance()->arguments().contains("-silent")) {
|
||||||
settings()->setSilentStart(true);
|
settings()->setSilentStart(true);
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
#include <QUrl>
|
#include <QUrl>
|
||||||
#include <QtGlobal>
|
#include <QtGlobal>
|
||||||
#include <qqml.h>
|
#include <qqml.h>
|
||||||
|
#include <QtGlobal>
|
||||||
|
|
||||||
#include <QtWebEngine>
|
#include <QtWebEngine>
|
||||||
|
|
||||||
@ -59,7 +60,7 @@ class App : public QObject {
|
|||||||
public:
|
public:
|
||||||
explicit App();
|
explicit App();
|
||||||
|
|
||||||
#if QT_VERSION < QT_VERSION_CHECK(5, 14, 0)
|
#if QT_VERSION >= QT_VERSION_CHECK(5, 14, 0)
|
||||||
static App* instance()
|
static App* instance()
|
||||||
{
|
{
|
||||||
static App app;
|
static App app;
|
||||||
@ -218,7 +219,7 @@ public slots:
|
|||||||
}
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
#if QT_VERSION > QT_VERSION_CHECK(5, 14, 0)
|
#if QT_VERSION >= QT_VERSION_CHECK(5, 14, 0)
|
||||||
unique_ptr<QQmlApplicationEngine> m_mainWindowEngine;
|
unique_ptr<QQmlApplicationEngine> m_mainWindowEngine;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user