Skip to content

Commit d004791

Browse files
committedJun 9, 2013
[Plugin Manager] Temporarily hardcode QGIS_VERSION=2.0.0 in the QgsPluginInstaller and QgsPluginRegistry to allow proper version comparision until it's globally set before the release.
1 parent 5c50e2a commit d004791

File tree

3 files changed

+30
-0
lines changed

3 files changed

+30
-0
lines changed
 

‎python/pyplugin_installer/installer.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,17 @@
3434
from qgsplugininstallerrepositorydialog import QgsPluginInstallerRepositoryDialog
3535

3636

37+
################################################################################
38+
################################################################################
39+
### TEMPORARY WORKAROUND UNTIL VERSION NUMBER IS GLOBALY SWITCHED TO 2.0 #######
40+
################################################################################
41+
class QGis: ##################################
42+
QGIS_VERSION_INT = 20000 ##################################
43+
QGIS_VERSION = '2.0.0-Master' ##################################
44+
################################################################################
45+
################################################################################
46+
47+
3748
# public instances:
3849
pluginInstaller = None
3950

‎python/pyplugin_installer/installer_data.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -125,6 +125,15 @@
125125

126126

127127

128+
################################################################################
129+
################################################################################
130+
### TEMPORARY WORKAROUND UNTIL VERSION NUMBER IS GLOBALY SWITCHED TO 2.0 #######
131+
################################################################################
132+
class QGis: ##################################
133+
QGIS_VERSION_INT = 20000 ##################################
134+
QGIS_VERSION = '2.0.0-Master' ##################################
135+
################################################################################
136+
################################################################################
128137

129138

130139
# --- common functions ------------------------------------------------------------------- #

‎src/app/qgspluginregistry.cpp

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -237,6 +237,16 @@ bool QgsPluginRegistry::checkQgisVersion( QString minVersion, QString maxVersion
237237

238238
// our qgis version - cut release name after version number
239239
QString qgisVersion = QString( QGis::QGIS_VERSION ).section( '-', 0, 0 );
240+
241+
// /////////////////////////////////////////////////////////////////////////////
242+
// TEMPORARY WORKAROUND UNTIL VERSION NUMBER IS GLOBALY SWITCHED TO 2.0 //
243+
// /////////////////////////////////////////////////////////////////////////////
244+
// //////////////////////////////////
245+
qgisVersion = "2.0.0"; //////////////////////////////////
246+
// //////////////////////////////////
247+
// /////////////////////////////////////////////////////////////////////////////
248+
// /////////////////////////////////////////////////////////////////////////////
249+
240250
QStringList qgisVersionParts = qgisVersion.split( "." );
241251

242252
int qgisMajor = qgisVersionParts.at( 0 ).toInt();

0 commit comments

Comments
 (0)
Please sign in to comment.