From a9170d35ca2491cdafc8a24ad6cb6a535ec57a3a Mon Sep 17 00:00:00 2001 From: Elias Steurer Date: Sun, 14 Mar 2021 12:01:46 +0100 Subject: [PATCH] Add version as from class --- ScreenPlay/app.cpp | 7 ++++++- ScreenPlay/app.h | 2 +- ScreenPlay/main.qml | 2 +- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/ScreenPlay/app.cpp b/ScreenPlay/app.cpp index 97fb54d9..54eb637f 100644 --- a/ScreenPlay/app.cpp +++ b/ScreenPlay/app.cpp @@ -54,7 +54,7 @@ App::App() QGuiApplication::setOrganizationName("ScreenPlay"); QGuiApplication::setOrganizationDomain("https://screen-play.app"); QGuiApplication::setApplicationName("ScreenPlay"); - QGuiApplication::setApplicationVersion("0.13.0"); + QGuiApplication::setApplicationVersion("0.13.1"); QGuiApplication::setQuitOnLastWindowClosed(false); QFontDatabase::addApplicationFont(":/assets/fonts/LibreBaskerville-Italic.ttf"); @@ -208,6 +208,11 @@ void App::init() QObject::connect(m_monitorListModel.get(), &MonitorListModel::monitorConfigurationChanged, m_screenPlayManager.get(), &ScreenPlayManager::closeAllWallpapers); } +QString App::version() const +{ + return QGuiApplication::applicationVersion(); +} + /*! \brief Tries to send the telemetry quit event before we call quit ourself. */ diff --git a/ScreenPlay/app.h b/ScreenPlay/app.h index 36e597d1..33ce1e40 100644 --- a/ScreenPlay/app.h +++ b/ScreenPlay/app.h @@ -118,7 +118,7 @@ signals: void wizardsChanged(Wizards* wizards); public slots: - + QString version() const; void exit(); bool loadSteamPlugin(); bool unloadSteamPlugin(); diff --git a/ScreenPlay/main.qml b/ScreenPlay/main.qml index 01c508ab..39a41a11 100644 --- a/ScreenPlay/main.qml +++ b/ScreenPlay/main.qml @@ -24,7 +24,7 @@ ApplicationWindow { visible: false width: 1400 height: 788 - title: "ScreenPlay Alpha - 0.13.0" + title: "ScreenPlay Alpha - " + ScreenPlay.version(); minimumHeight: 450 minimumWidth: 1050 onVisibilityChanged: {