From 4e7f393aab6178fadf4cb65ecd15f6012bcd8a0b Mon Sep 17 00:00:00 2001 From: konrad Date: Sat, 3 Dec 2011 20:51:27 +0000 Subject: [PATCH] make compatible with Qt5 and unified versions in WOC git-svn-id: https://silmor.de/svn/softmagic/smoke/trunk@755 6e3c4bff-ac9f-4ac1-96c5-d2ea494d3e33 --- src/dialogs/configdialog.cpp | 2 +- src/dialogs/orderwin.h | 1 + src/iface/msinterface.cpp | 7 ------- src/iface/msinterface.h | 4 ---- src/main.cpp | 9 +++++---- src/smoke.pro | 3 +++ 6 files changed, 10 insertions(+), 16 deletions(-) diff --git a/src/dialogs/configdialog.cpp b/src/dialogs/configdialog.cpp index 2b54711..a68968b 100644 --- a/src/dialogs/configdialog.cpp +++ b/src/dialogs/configdialog.cpp @@ -573,7 +573,7 @@ void MConfigDialog::sslErrors(QNetworkReply*rp,const QList&errs) for(int i=0;i1)return l[1]; - else return svnRepositoryUrl(); -} - bool MSInterface::hasRight(Right r)const { if(userroles.contains("_admin"))return true; diff --git a/src/iface/msinterface.h b/src/iface/msinterface.h index 8b499e3..bb54c22 100644 --- a/src/iface/msinterface.h +++ b/src/iface/msinterface.h @@ -30,7 +30,6 @@ class MSInterface:public MInterface Q_PROPERTY(QString dataDir READ dataDir) Q_PROPERTY(QString settingsGroup READ settingsGroup) Q_PROPERTY(QString sessionId READ sessionId) - Q_PROPERTY(QString repoPart READ repoPart) Q_PROPERTY(QString profileId READ profileId) public: /**creates the interface object, expects the profile ID as parameter*/ @@ -69,9 +68,6 @@ class MSInterface:public MInterface /**returns the current session ID*/ Q_INVOKABLE QString sessionId()const{return m_sessid;} - /**returns the branch/trunk part of the repository*/ - Q_INVOKABLE static QString repoPart(); - /**returns default headers, ie. session ID*/ virtual QMap headers(QString)const; diff --git a/src/main.cpp b/src/main.cpp index d709f30..1c9976d 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -91,9 +91,9 @@ void MApplication::aboutMS() "protected under the GNU GPL v.3 or at your option any newer

" "See also the MagicSmoke Homepage.

" "This version was compiled from repository '%1' revision '%2'.") - .arg(MSInterface::repoPart()) // %1 - .arg(MInterface::svnVersion()) //%2 - .arg(MSInterface::version()) //%3 + .arg(MSInterface::staticVersionInfo(WOb::VersionRootURL)) // %1 + .arg(MInterface::staticVersionInfo(WOb::VersionNumber)) //%2 + .arg(MSInterface::staticVersionInfo(WOb::VersionHR)) //%3 .arg(HOMEPAGE_BASEURL) //%4 ); mb.setStandardButtons(QMessageBox::Ok); @@ -145,8 +145,9 @@ QMenu* MApplication::helpMenu() void MApplication::help() { QString d=QApplication::applicationDirPath()+"/doc/index.html"; + //TODO: fix this to work with GIT and be more generic if(!QFile(d).exists()){ - d=HOMEPAGE_BASEURL "/doc/"+MSInterface::repoPart()+"/index.html"; + d=HOMEPAGE_BASEURL "/doc/"+MSInterface::staticVersionInfo(WOb::VersionPath)+"/index.html"; }else d="file:///"+d; QDesktopServices::openUrl(QUrl(d)); } diff --git a/src/smoke.pro b/src/smoke.pro index d99e3b2..631d1c1 100644 --- a/src/smoke.pro +++ b/src/smoke.pro @@ -10,6 +10,9 @@ CONFIG += debug CONFIG += qt thread link_prl QT += xml network script scripttools +contains(QT_MAJOR_VERSION,"5") { + QT += widgets printsupport +} win32-* { #RC-File containing the icon: -- 1.7.2.5