[GRASS-SVN] r62824 - grass/trunk/gui/wxpython/gui_core
svn_grass at osgeo.org
svn_grass at osgeo.org
Wed Nov 19 18:46:54 PST 2014
Author: annakrat
Date: 2014-11-19 18:46:54 -0800 (Wed, 19 Nov 2014)
New Revision: 62824
Modified:
grass/trunk/gui/wxpython/gui_core/forms.py
Log:
wxGUI: fix closing d.* dialog of a new layer which was removed
Modified: grass/trunk/gui/wxpython/gui_core/forms.py
===================================================================
--- grass/trunk/gui/wxpython/gui_core/forms.py 2014-11-20 02:34:20 UTC (rev 62823)
+++ grass/trunk/gui/wxpython/gui_core/forms.py 2014-11-20 02:46:54 UTC (rev 62824)
@@ -765,7 +765,11 @@
self.Hide()
# canceled layer with nothing set
elif len(self.parent.GetLayerInfo(self.layer, key = 'cmd')) < 1:
- self.parent.Delete(self.layer)
+ try:
+ self.parent.Delete(self.layer)
+ except ValueError:
+ # happens when closing dialog of a new layer which was removed from tree
+ pass
self.Destroy()
else:
# cancel for non-display commands
More information about the grass-commit
mailing list