From adc52782f8855bdd034b8290c530095e39aecb57 Mon Sep 17 00:00:00 2001 From: l_maliakal_d Date: Fri, 14 Dec 2012 13:45:38 +0000 Subject: [PATCH] gui svninfo added to script git-svn-id: file:///afs/psi.ch/project/sls_det_software/svn/slsDetectorGui@123 af1100a4-978c-4157-bff7-07162d2ba061 --- slsDetectorGui/include/qDefs.h | 2 +- slsDetectorGui/slsDetectorGui.pro | 2 +- slsDetectorGui/src/qDetectorMain.cpp | 8 +++++++- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/slsDetectorGui/include/qDefs.h b/slsDetectorGui/include/qDefs.h index 626dafe91..600e01e2b 100644 --- a/slsDetectorGui/include/qDefs.h +++ b/slsDetectorGui/include/qDefs.h @@ -21,7 +21,7 @@ public: qDefs(){}; //------------------------------------------------------------------------------------------------------------------------------------------------- -#define GUI_VERSION 0.14 +static const int64_t GUI_VERSION=0x20121213; //------------------------------------------------------------------------------------------------------------------------------------------------- diff --git a/slsDetectorGui/slsDetectorGui.pro b/slsDetectorGui/slsDetectorGui.pro index df565fcaa..d05907e6f 100644 --- a/slsDetectorGui/slsDetectorGui.pro +++ b/slsDetectorGui/slsDetectorGui.pro @@ -22,7 +22,7 @@ CONFIG += debug no_include_pwd QMAKE_CXXFLAGS_WARN_ON = -w QMAKE_CFLAGS_WARN_ON = -w -DEFINES += VERBOSE DACS_INT #VERYVERBOSE +DEFINES += VERBOSE DACS_INT THIS_PATH=\\\"$$PWD\\\" #VERYVERBOSE target.path += $(DESTDIR) diff --git a/slsDetectorGui/src/qDetectorMain.cpp b/slsDetectorGui/src/qDetectorMain.cpp index f00b3494c..b6af48bb0 100644 --- a/slsDetectorGui/src/qDetectorMain.cpp +++ b/slsDetectorGui/src/qDetectorMain.cpp @@ -19,6 +19,7 @@ #include "slsDetector.h" #include "multiSlsDetector.h" #include "sls_detector_defs.h" +#include "svnInfo.h" // Qt Include Headers #include #include @@ -531,11 +532,16 @@ void qDetectorMain::ExecuteHelp(QAction *action){ cout << "About: Common GUI for Mythen, Eiger, Gotthard and Agipd detectors" << endl; #endif char version[200]; + svnInfo* s = new svnInfo(string(THIS_PATH)); + sprintf(version,"%llx",(qDefs::GUI_VERSION<<32) | (s->getRevision())); + string thisGUIVersion = string(version); + sprintf(version,"%llx",myDet->getId(slsDetectorDefs::THIS_SOFTWARE_VERSION)); string thisClientVersion = string(version); + //

A heading

qDefs::Message(qDefs::INFORMATION,"

" - "SLS Detector GUI version: " + string(QString("%1").arg(GUI_VERSION).toAscii().constData())+"
" + "SLS Detector GUI version:   " + thisGUIVersion+"
" "SLS Detector Client version: "+thisClientVersion+"

" "Common GUI to control the SLS Detectors: " "Mythen, Eiger, Gotthard and Agipd.

"