[GRASS-SVN] r54478 - grass/trunk/gui/wxpython/gui_core

svn_grass at osgeo.org svn_grass at osgeo.org
Tue Jan 1 10:51:42 PST 2013


Author: martinl
Date: 2013-01-01 10:51:42 -0800 (Tue, 01 Jan 2013)
New Revision: 54478

Modified:
   grass/trunk/gui/wxpython/gui_core/dialogs.py
Log:
wxGUI: fix GroupDialog when group with given name does not exist


Modified: grass/trunk/gui/wxpython/gui_core/dialogs.py
===================================================================
--- grass/trunk/gui/wxpython/gui_core/dialogs.py	2013-01-01 18:49:35 UTC (rev 54477)
+++ grass/trunk/gui/wxpython/gui_core/dialogs.py	2013-01-01 18:51:42 UTC (rev 54478)
@@ -1081,13 +1081,13 @@
                 self.ApplyChanges()
                 
             dlg.Destroy()
-            
-            
         
+        maps = list()
         groups = self.GetExistGroups()
         if group in groups:
-            self.ShowGroupLayers(self.GetGroupLayers(group))
-            
+            maps = self.GetGroupLayers(group)
+        
+        self.ShowGroupLayers(maps)
         self.currentGroup = group
         self.groupChanged = False
         
@@ -1096,8 +1096,7 @@
     def ShowGroupLayers(self, mapList):
         """!Show map layers in currently selected group"""
         self.layerBox.Set(mapList)
-        
-        
+                
     def EditGroup(self, group):
         """!Edit selected group"""
         layersNew = self.GetLayers()
@@ -1168,7 +1167,7 @@
                 label = _("Creating of new group <%s> failed.") % group
             else:
                 label = _("Changing of group <%s> failed.") % group
-                
+            
         self.infoLabel.SetLabel(label)
         wx.FutureCall(4000, self.ClearNotification)
         



More information about the grass-commit mailing list