[GRASS-SVN] r48701 - grass/branches/develbranch_6/gui/wxpython/gui_modules

svn_grass at osgeo.org svn_grass at osgeo.org
Sun Oct 9 18:33:58 EDT 2011


Author: martinl
Date: 2011-10-09 15:33:58 -0700 (Sun, 09 Oct 2011)
New Revision: 48701

Modified:
   grass/branches/develbranch_6/gui/wxpython/gui_modules/gmodeler.py
Log:
wxGUI/modeler: support also mapsets


Modified: grass/branches/develbranch_6/gui/wxpython/gui_modules/gmodeler.py
===================================================================
--- grass/branches/develbranch_6/gui/wxpython/gui_modules/gmodeler.py	2011-10-09 22:20:49 UTC (rev 48700)
+++ grass/branches/develbranch_6/gui/wxpython/gui_modules/gmodeler.py	2011-10-09 22:33:58 UTC (rev 48701)
@@ -597,13 +597,13 @@
                                        'idx' : idx }
             for name, values in self.variables.iteritems():
                 gtype = values.get('type', 'string')
-                if gtype in ('raster', 'vector'):
+                if gtype in ('raster', 'vector', 'mapset'):
                     gisprompt = True
                     prompt = gtype
                     if gtype == 'raster':
                         element = 'cell'
                     else:
-                        element = 'vector'
+                        element = gtype
                     ptype = 'string'
                 else:
                     gisprompt = False
@@ -611,12 +611,12 @@
                     element = None
                     ptype = gtype
                 params.append({ 'gisprompt' : gisprompt,
-                                'multiple'  : 'no',
+                                'multiple'  : False,
                                 'description' : values.get('description', ''),
                                 'guidependency' : '',
                                 'default' : '',
                                 'age' : None,
-                                'required' : 'yes',
+                                'required' : True,
                                 'value' : values.get('value', ''),
                                 'label' : '',
                                 'guisection' : '',
@@ -3701,6 +3701,7 @@
         for name in nameOrdered:
             params = self.params[name]
             panel = self._createPage(name, params)
+            
             self.notebook.AddPage(panel, text = name)
         
         return panel
@@ -3802,7 +3803,8 @@
                                          _("float"),
                                          _("string"),
                                          _("raster"),
-                                         _("vector")])
+                                         _("vector"),
+                                         _("mapset")])
         self.value = wx.TextCtrl(parent = self, id = wx.ID_ANY)
         self.desc = wx.TextCtrl(parent = self, id = wx.ID_ANY)
         



More information about the grass-commit mailing list