[GRASS-SVN] r54503 - grass/trunk/gui/wxpython/iclass
svn_grass at osgeo.org
svn_grass at osgeo.org
Wed Jan 2 09:24:31 PST 2013
Author: martinl
Date: 2013-01-02 09:24:30 -0800 (Wed, 02 Jan 2013)
New Revision: 54503
Modified:
grass/trunk/gui/wxpython/iclass/frame.py
grass/trunk/gui/wxpython/iclass/g.gui.iclass.py
Log:
wxGUI/iclass: check topology also for vector maps imported from command line (g.gui.iclass tr=)
Modified: grass/trunk/gui/wxpython/iclass/frame.py
===================================================================
--- grass/trunk/gui/wxpython/iclass/frame.py 2013-01-02 17:16:37 UTC (rev 54502)
+++ grass/trunk/gui/wxpython/iclass/frame.py 2013-01-02 17:24:30 UTC (rev 54503)
@@ -476,10 +476,7 @@
dlg = IClassMapDialog(self, title = _("Import vector map"), element = 'vector')
if dlg.ShowModal() == wx.ID_OK:
vName = dlg.GetMap()
- warning = self._checkImportedTopo(vName)
- if warning:
- GMessage(parent = self, message = warning)
-
+
self.ImportAreas(vName)
dlg.Destroy()
@@ -509,6 +506,11 @@
@param vector vector map name
"""
+ warning = self._checkImportedTopo(vector)
+ if warning:
+ GMessage(parent = self, message = warning)
+ return
+
wx.BeginBusyCursor()
wx.Yield()
Modified: grass/trunk/gui/wxpython/iclass/g.gui.iclass.py
===================================================================
--- grass/trunk/gui/wxpython/iclass/g.gui.iclass.py 2013-01-02 17:16:37 UTC (rev 54502)
+++ grass/trunk/gui/wxpython/iclass/g.gui.iclass.py 2013-01-02 17:24:30 UTC (rev 54503)
@@ -90,6 +90,8 @@
# show main frame
giface = StandaloneGrassInterface()
frame = IClassMapFrame(parent = None, giface = giface)
+ if not flags['m']:
+ frame.CenterOnScreen()
if group_name:
frame.SetGroup(group_name)
if map_name:
@@ -99,8 +101,6 @@
giface.WriteLog(_("Loading training map <%s>...") % trainingmap_name)
frame.ImportAreas(trainingmap_name)
- if not flags['m']:
- frame.CenterOnScreen()
frame.Show()
if flags['m']:
frame.Maximize()
More information about the grass-commit
mailing list