[GRASS-SVN] r32805 -
grass/branches/develbranch_6/gui/wxpython/gui_modules
svn_grass at osgeo.org
svn_grass at osgeo.org
Sat Aug 16 03:31:54 EDT 2008
Author: cmbarton
Date: 2008-08-16 03:31:54 -0400 (Sat, 16 Aug 2008)
New Revision: 32805
Modified:
grass/branches/develbranch_6/gui/wxpython/gui_modules/gdialogs.py
grass/branches/develbranch_6/gui/wxpython/gui_modules/menuform.py
Log:
Fixed bugs in display decorations. Opening properties dialogs caused errors and dialogs would not close.
Modified: grass/branches/develbranch_6/gui/wxpython/gui_modules/gdialogs.py
===================================================================
--- grass/branches/develbranch_6/gui/wxpython/gui_modules/gdialogs.py 2008-08-16 06:02:01 UTC (rev 32804)
+++ grass/branches/develbranch_6/gui/wxpython/gui_modules/gdialogs.py 2008-08-16 07:31:54 UTC (rev 32805)
@@ -374,24 +374,23 @@
self.parent.MapWindow.overlays[self.ovlId]['propwin'] = propwin
# change parameters for item in layers list in render.Map
- # "Use mouse..." (-m) flag causes GUI freeze, trac #119
+ # "Use mouse..." (-m) flag causes GUI freeze and is pointless here, trac #119
+
try:
self.parent.MapWindow.overlays[self.ovlId]['cmd'].remove('-m')
except ValueError:
pass
-
+
self.parent.Map.ChangeOverlay(id=self.ovlId, type=self.name,
command=self.parent.MapWindow.overlays[self.ovlId]['cmd'],
l_active=self.parent.MapWindow.overlays[self.ovlId]['layer'].IsActive(),
l_render=False, l_hidden=True)
-
- if self.name == 'legend' and \
- params and \
- not self.btnOK.IsEnabled():
- self.btnOK.Enable()
+ if self.name == 'legend':
+ if params and not self.btnOK.IsEnabled():
+ self.btnOK.Enable()
- self.SetTitle(_('Legend of raster map <%s>') % \
- utils.GetLayerNameFromCmd(self.parent.MapWindow.overlays[self.ovlId]['cmd']))
+ #self.SetTitle(_('Legend of raster map <%s>') % \
+ # utils.GetLayerNameFromCmd(self.parent.MapWindow.overlays[self.ovlId]['cmd']))
class TextLayerDialog(wx.Dialog):
"""
Modified: grass/branches/develbranch_6/gui/wxpython/gui_modules/menuform.py
===================================================================
--- grass/branches/develbranch_6/gui/wxpython/gui_modules/menuform.py 2008-08-16 06:02:01 UTC (rev 32804)
+++ grass/branches/develbranch_6/gui/wxpython/gui_modules/menuform.py 2008-08-16 07:31:54 UTC (rev 32805)
@@ -826,10 +826,11 @@
"""Cancel button pressed"""
self.MakeModal(False)
if self.get_dcmd:
- if len(self.parent.GetPyData(self.layer)[0]['cmd']) < 1:
- self.parent.Delete(self.layer)
- self.Destroy()
- else:
+ try:
+ if len(self.parent.GetPyData(self.layer)[0]['cmd']) < 1:
+ self.parent.Delete(self.layer)
+ self.Destroy()
+ except:
self.Hide()
else:
self.Destroy()
More information about the grass-commit
mailing list