[GRASS-SVN] r65749 - grass/trunk/gui/wxpython/gui_core
svn_grass at osgeo.org
svn_grass at osgeo.org
Tue Jul 21 03:45:37 PDT 2015
Author: annakrat
Date: 2015-07-21 03:45:36 -0700 (Tue, 21 Jul 2015)
New Revision: 65749
Modified:
grass/trunk/gui/wxpython/gui_core/forms.py
Log:
wxGUI: fix reopening d.vect.thematic properties with multiple colors
Modified: grass/trunk/gui/wxpython/gui_core/forms.py
===================================================================
--- grass/trunk/gui/wxpython/gui_core/forms.py 2015-07-21 10:41:10 UTC (rev 65748)
+++ grass/trunk/gui/wxpython/gui_core/forms.py 2015-07-21 10:45:36 UTC (rev 65749)
@@ -1470,7 +1470,8 @@
if p.get('default','') != '':
default_color, label_color = utils.color_resolve(p['default'])
if p.get('value','') != '' and p.get('value','') != 'none': # parameter previously set
- default_color, label_color = utils.color_resolve(p['value'])
+ if not p.get('multiple', False):
+ default_color, label_color = utils.color_resolve(p['value'])
if p.get('element', '') == 'color_none' or p.get('multiple', False):
this_sizer = wx.BoxSizer(orient = wx.HORIZONTAL)
else:
@@ -1485,6 +1486,8 @@
this_sizer.Add(item = txt, proportion = 1,
flag = wx.ADJUST_MINSIZE | wx.LEFT | wx.TOP, border = 5)
txt.Bind(wx.EVT_TEXT, self.OnSetValue)
+ if p.get('value', ''):
+ txt.SetValue(p['value'])
colorSize = 40
label_color = ''
p['wxId'][1] = txt.GetId()
More information about the grass-commit
mailing list