Made the version configurable from CMake and bumped the version to 2.0.900.

This commit is contained in:
Micke Prag 2010-03-05 09:21:03 +00:00
parent 0bb6e71ca2
commit 5da94a98da
3 changed files with 10 additions and 4 deletions

View file

@ -6,8 +6,9 @@ if(COMMAND cmake_policy)
cmake_policy(SET CMP0003 NEW)
endif(COMMAND cmake_policy)
SET(PACKAGE_VERSION 2)
SET(PACKAGE_SOVERSION 2.0.0)
SET(PACKAGE_VERSION 2.0.900)
SET(PACKAGE_SOVERSION 2)
SET(DISPLAYED_VERSION ${PACKAGE_VERSION})
SET(UPDATE_TRANSLATIONS FALSE CACHE BOOL "Update source translation files (WARNING: make clean will delete the source .ts files! Danger!)")
SET(LANGUAGES sv)

View file

@ -46,6 +46,8 @@ SET( telldus-center_LIBRARIES
${QT_LIBRARIES}
)
ADD_DEFINITIONS( -DVERSION="${DISPLAYED_VERSION}" )
######## Configurable options for the platform ########

View file

@ -16,6 +16,9 @@
#include "message.h"
#include "plugintree.h"
#define VERSION_STRING_HELPER(X) #X
#define VERSION_STRING(X) VERSION_STRING_HELPER(X)
class MainWindowPrivate {
public:
QToolBar *pagesBar;
@ -123,8 +126,8 @@ void MainWindow::addWidget( const QString &page, const QIcon &icon, QWidget *wid
void MainWindow::slotAboutApplication() {
QMessageBox::about(this, tr("About Telldus Center"),
tr("<center><img src=':/images/TelldusCenter_128.png' width=128 height=128 /><h2>Telldus Center 2.0.1</h2>"
"<p>Copyright &copy; 2009 Telldus Technologies AB<p></center>"));
tr("<center><img src=':/images/TelldusCenter_128.png' width=128 height=128 /><h2>Telldus Center %1</h2>"
"<p>Copyright &copy; 2010 Telldus Technologies AB<p></center>").arg(VERSION_STRING(VERSION)));
}
void MainWindow::slotPagesClick() {