use APPVERSION define

...and display version in about dialog
This commit is contained in:
Peter Eszlari
2019-12-06 06:45:08 +01:00
parent c32a1c8be2
commit 052ae7325a
3 changed files with 6 additions and 5 deletions
+1 -1
View File
@@ -29,7 +29,7 @@ set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTOUIC ON)
set(CMAKE_AUTORCC ON)
set(OLIVE_DEFINITIONS -DQT_DEPRECATED_WARNINGS)
set(OLIVE_DEFINITIONS -DAPPVERSION="${PROJECT_VERSION}" -DQT_DEPRECATED_WARNINGS)
list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake")
+4 -3
View File
@@ -41,10 +41,11 @@ AboutDialog::AboutDialog(QWidget *parent) :
"<span style=\" text-decoration: underline; color:#007af4;\">"
"https://www.olivevideoeditor.org/"
"</span></a></p>"
"<p><b>%1</b></p>" // AppName (version identifier)
"<p>%2</p>" // First statement
"<p>%3</p>" // Second statement
"<p><b>%1</b> %2</p>" // AppName (version identifier)
"<p>%3</p>" // First statement
"<p>%4</p>" // Second statement
"</body></html>").arg(QApplication::applicationName(),
QApplication::applicationVersion(),
tr("Olive is a non-linear video editor. This software is free and "
"protected by the GNU GPL."),
tr("Olive Team is obliged to inform users that Olive source code is "
+1 -1
View File
@@ -55,7 +55,7 @@ int main(int argc, char *argv[]) {
QCoreApplication::setOrganizationDomain("olivevideoeditor.org");
QCoreApplication::setApplicationName("Olive");
QString app_version = "0.2.0";
QString app_version = APPVERSION;
#ifdef GITHASH
// Anything after the hyphen is considered "unimportant" information. Text BEFORE the hyphen is used in version
// checking project files and config files