浏览代码

wxGUI: implement SetSelection() from MapsetSelect (backward compatibility)

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@59222 15284696-431f-4ddb-bdfa-cd5b030d7da7
Martin Landa 11 年之前
父节点
当前提交
e6280a7386
共有 2 个文件被更改,包括 7 次插入1 次删除
  1. 1 1
      gui/wxpython/gui_core/dialogs.py
  2. 6 0
      gui/wxpython/gui_core/gselect.py

+ 1 - 1
gui/wxpython/gui_core/dialogs.py

@@ -115,7 +115,7 @@ class LocationDialog(SimpleDialog):
                                      setItems = False, skipCurrent = True,
                                      validator = SimpleValidator(callback = self.ValidatorCallback))
         self.element1.SetFocus()
-        self.warning = _("Location or mapset is missing.")
+        self.warning = _("Location or mapset is not defined.")
         self._layout()
         self.SetMinSize(self.GetSize())
 

+ 6 - 0
gui/wxpython/gui_core/gselect.py

@@ -1176,6 +1176,12 @@ class MapsetSelect(wx.combo.ComboCtrl):
         wx.ComboBox to wx.combo.ComboCtrl"""
         return self.SetValue(text)
 
+    def SetSelection(self, sel=0):
+        """!For backward compatibility. MapsetSelect changed to allow
+        multiple selection, this required to change super-class from
+        wx.ComboBox to wx.combo.ComboCtrl"""
+        self.SetValue('') # TODO: implement SetSelection()
+
     def SetItems(self, items):
         """!For backward compatibility. MapsetSelect changed to allow
         multiple selection, this required to change super-class from