[GRASS-SVN] r49570 -
grass/branches/develbranch_6/gui/wxpython/gui_modules
svn_grass at osgeo.org
svn_grass at osgeo.org
Tue Dec 6 12:43:45 EST 2011
Author: martinl
Date: 2011-12-06 09:43:45 -0800 (Tue, 06 Dec 2011)
New Revision: 49570
Modified:
grass/branches/develbranch_6/gui/wxpython/gui_modules/ghelp.py
Log:
wxGUI/extension: fix loading extensions without any prefix
Modified: grass/branches/develbranch_6/gui/wxpython/gui_modules/ghelp.py
===================================================================
--- grass/branches/develbranch_6/gui/wxpython/gui_modules/ghelp.py 2011-12-06 17:31:04 UTC (rev 49569)
+++ grass/branches/develbranch_6/gui/wxpython/gui_modules/ghelp.py 2011-12-06 17:43:45 UTC (rev 49570)
@@ -1038,7 +1038,7 @@
's' : 'sites',
'v' : 'vector',
'wx' : 'wxGUI',
- 'u' : 'other' }
+ '' : 'other' }
if c in name:
return name[c]
@@ -1080,7 +1080,7 @@
try:
prefix, name = value.split('.', 1)
except ValueError:
- prefix = 'u'
+ prefix = ''
name = value
if prefix not in mdict:
mdict[prefix] = dict()
@@ -1091,11 +1091,11 @@
try:
prefix, name = line.strip().split('.', 1)
except:
- prefix = 'unknown'
+ prefix = ''
name = line.strip()
if self._expandPrefix(prefix) == prefix:
- prefix = 'unknown'
+ prefix = ''
if prefix not in mdict:
mdict[prefix] = dict()
@@ -1108,8 +1108,12 @@
names = mdict[prefix].keys()
names.sort()
for name in names:
+ if prefix:
+ text = prefix + '.' + name
+ else:
+ text = name
new = self.AppendItem(parentId = item,
- text = prefix + '.' + name)
+ text = text)
data = dict()
for key in mdict[prefix][name].keys():
data[key] = mdict[prefix][name][key]
More information about the grass-commit
mailing list