[GRASS-SVN] r42557 - in grass/branches/develbranch_6/gui/wxpython:
gui_modules xml
svn_grass at osgeo.org
svn_grass at osgeo.org
Mon Jun 14 04:35:37 EDT 2010
Author: martinl
Date: 2010-06-14 08:35:36 +0000 (Mon, 14 Jun 2010)
New Revision: 42557
Modified:
grass/branches/develbranch_6/gui/wxpython/gui_modules/globalvar.py
grass/branches/develbranch_6/gui/wxpython/gui_modules/gmodeler.py
grass/branches/develbranch_6/gui/wxpython/xml/menudata_modeler.xml
Log:
wxGUI/modeler: various minor fixes
(merge r42556 from trunk)
Modified: grass/branches/develbranch_6/gui/wxpython/gui_modules/globalvar.py
===================================================================
--- grass/branches/develbranch_6/gui/wxpython/gui_modules/globalvar.py 2010-06-14 08:32:49 UTC (rev 42556)
+++ grass/branches/develbranch_6/gui/wxpython/gui_modules/globalvar.py 2010-06-14 08:35:36 UTC (rev 42557)
@@ -18,6 +18,8 @@
import sys
import locale
+if not os.getenv("GISBASE"):
+ sys.exit("GRASS is not running. Exiting...")
### i18N
import gettext
gettext.install('grasswxpy', os.path.join(os.getenv("GISBASE"), 'locale'), unicode=True)
Modified: grass/branches/develbranch_6/gui/wxpython/gui_modules/gmodeler.py
===================================================================
--- grass/branches/develbranch_6/gui/wxpython/gui_modules/gmodeler.py 2010-06-14 08:32:49 UTC (rev 42556)
+++ grass/branches/develbranch_6/gui/wxpython/gui_modules/gmodeler.py 2010-06-14 08:35:36 UTC (rev 42557)
@@ -1047,7 +1047,7 @@
# add action to canvas
width, height = self.canvas.GetSize()
- action = ModelAction(self, cmd = cmd, x = width/2, y = height/2,
+ action = ModelAction(self.model, cmd = cmd, x = width/2, y = height/2,
id = len(self.model.GetActions()) + 1)
overwrite = self.model.GetProperties().get('overwrite', None)
if overwrite is not None:
@@ -1914,6 +1914,7 @@
shape.InsertLineControlPoint(point = wx.RealPoint(self.x, self.y))
shape.ResetShapes()
shape.Select(True)
+ self.frame.ModelChanged()
self.frame.canvas.Refresh()
def OnRemovePoint(self, event):
@@ -1922,6 +1923,7 @@
shape.DeleteLineControlPoint()
shape.Select(False)
shape.Select(True)
+ self.frame.ModelChanged()
self.frame.canvas.Refresh()
def OnIntermediate(self, event):
Modified: grass/branches/develbranch_6/gui/wxpython/xml/menudata_modeler.xml
===================================================================
--- grass/branches/develbranch_6/gui/wxpython/xml/menudata_modeler.xml 2010-06-14 08:32:49 UTC (rev 42556)
+++ grass/branches/develbranch_6/gui/wxpython/xml/menudata_modeler.xml 2010-06-14 08:35:36 UTC (rev 42557)
@@ -82,8 +82,8 @@
<handler>OnDefineRelation</handler>
</menuitem>
<menuitem>
- <label>Define loop</label>
- <help>Defines loop in the model</help>
+ <label>Add loop</label>
+ <help>Adds loop to model</help>
<handler>OnDefineLoop</handler>
<shortcut>Ctrl+L</shortcut>
</menuitem>
More information about the grass-commit
mailing list