[GRASS-SVN] r70012 - grass/branches/releasebranch_7_2/gui/wxpython/vdigit

svn_grass at osgeo.org svn_grass at osgeo.org
Mon Dec 5 21:04:00 PST 2016


Author: annakrat
Date: 2016-12-05 21:04:00 -0800 (Mon, 05 Dec 2016)
New Revision: 70012

Modified:
   grass/branches/releasebranch_7_2/gui/wxpython/vdigit/toolbars.py
Log:
g.gui.vdigit: fix error when creating a new vector in standalone digitizer (merge from trunk, r70011)

Modified: grass/branches/releasebranch_7_2/gui/wxpython/vdigit/toolbars.py
===================================================================
--- grass/branches/releasebranch_7_2/gui/wxpython/vdigit/toolbars.py	2016-12-06 04:46:14 UTC (rev 70011)
+++ grass/branches/releasebranch_7_2/gui/wxpython/vdigit/toolbars.py	2016-12-06 05:04:00 UTC (rev 70012)
@@ -817,15 +817,14 @@
                                   disableAdd=True)
 
             if dlg and dlg.GetName():
-                # add layer to map layer tree
-                if self._giface.GetLayerTree():
-                    mapName = dlg.GetName() + '@' + grass.gisenv()['MAPSET']
-                    self._giface.GetLayerList().AddLayer(
+                # add layer to map layer tree/map display
+                mapName = dlg.GetName() + '@' + grass.gisenv()['MAPSET']
+                self._giface.GetLayerList().AddLayer(
                         ltype='vector', name=mapName, checked=True,
                         cmd=['d.vect', 'map=%s' % mapName])
 
-                    vectLayers = self.UpdateListOfLayers(updateTool=True)
-                    selection = vectLayers.index(mapName)
+                vectLayers = self.UpdateListOfLayers(updateTool=True)
+                selection = vectLayers.index(mapName)
 
                 # create table ?
                 if dlg.IsChecked('table'):



More information about the grass-commit mailing list