[GRASS-SVN] r62541 - grass/trunk/gui/wxpython/gui_core
svn_grass at osgeo.org
svn_grass at osgeo.org
Sun Nov 2 05:58:06 PST 2014
Author: annakrat
Date: 2014-11-02 05:58:06 -0800 (Sun, 02 Nov 2014)
New Revision: 62541
Modified:
grass/trunk/gui/wxpython/gui_core/dialogs.py
Log:
wxGUI: fix zoom to saved region, broken by r61356
Modified: grass/trunk/gui/wxpython/gui_core/dialogs.py
===================================================================
--- grass/trunk/gui/wxpython/gui_core/dialogs.py 2014-11-02 10:56:41 UTC (rev 62540)
+++ grass/trunk/gui/wxpython/gui_core/dialogs.py 2014-11-02 13:58:06 UTC (rev 62541)
@@ -510,8 +510,7 @@
box.Add(item=self._selection, proportion=0, flag=wx.ALIGN_CENTRE | wx.ALL, border=5)
self._selection.SetFocus()
- if self.loadsave == 'save':
- self._selection.Bind(wx.EVT_TEXT, self.OnRegion)
+ self._selection.Bind(wx.EVT_TEXT, self.OnRegion)
sizer.Add(item = box, proportion = 0, flag = wx.GROW | wx.ALIGN_CENTER_VERTICAL | wx.ALL,
border = 5)
@@ -538,6 +537,8 @@
def OnRegion(self, event):
value = self._selection.GetValue()
+ if '@' in value:
+ value = value.rsplit('@', 1)[0]
if not grass.legal_name(value):
GMessage(parent=self,
message=_("Name cannot begin with '.' "
More information about the grass-commit
mailing list