[GRASS-SVN] r41420 - grass/trunk/gui/wxpython/gui_modules
svn_grass at osgeo.org
svn_grass at osgeo.org
Sat Mar 13 11:47:55 EST 2010
Author: martinl
Date: 2010-03-13 11:47:53 -0500 (Sat, 13 Mar 2010)
New Revision: 41420
Modified:
grass/trunk/gui/wxpython/gui_modules/gselect.py
grass/trunk/gui/wxpython/gui_modules/menuform.py
Log:
wxGUI: ColumnSelect is not readonly (to unset option)
bugfix #998
Modified: grass/trunk/gui/wxpython/gui_modules/gselect.py
===================================================================
--- grass/trunk/gui/wxpython/gui_modules/gselect.py 2010-03-13 16:08:45 UTC (rev 41419)
+++ grass/trunk/gui/wxpython/gui_modules/gselect.py 2010-03-13 16:47:53 UTC (rev 41420)
@@ -666,9 +666,8 @@
size=globalvar.DIALOG_COMBOBOX_SIZE, vector=None,
layer=1, choices=[]):
- super(ColumnSelect, self).__init__(parent, id, value, pos, size, choices,
- style=wx.CB_READONLY)
-
+ super(ColumnSelect, self).__init__(parent, id, value, pos, size, choices)
+
self.SetName("ColumnSelect")
if vector:
Modified: grass/trunk/gui/wxpython/gui_modules/menuform.py
===================================================================
--- grass/trunk/gui/wxpython/gui_modules/menuform.py 2010-03-13 16:08:45 UTC (rev 41419)
+++ grass/trunk/gui/wxpython/gui_modules/menuform.py 2010-03-13 16:47:53 UTC (rev 41420)
@@ -1446,8 +1446,10 @@
size=globalvar.DIALOG_TEXTCTRL_SIZE)
win.Bind(wx.EVT_TEXT, self.OnSetValue)
elif p.get('prompt', '') == 'dbcolumn':
- win = gselect.ColumnSelect(parent=which_panel)
+ win = gselect.ColumnSelect(parent = which_panel,
+ value = p.get('default', ''))
win.Bind(wx.EVT_COMBOBOX, self.OnSetValue)
+ win.Bind(wx.EVT_TEXT, self.OnSetValue)
try:
p['wxId'] = [ win.GetId(), ]
@@ -1779,8 +1781,7 @@
break
if found:
- if name in ('LayerSelect', 'DriverSelect', 'TableSelect',
- 'ColumnSelect'):
+ if name in ('LayerSelect', 'DriverSelect', 'TableSelect'):
porf['value'] = me.GetStringSelection()
else:
porf['value'] = me.GetValue()
More information about the grass-commit
mailing list