Sfoglia il codice sorgente

Fix bug that throws bogus error message to console if you try to change the name of a previously selected GIS element using the tree combobox.

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@35393 15284696-431f-4ddb-bdfa-cd5b030d7da7
Michael Barton 16 anni fa
parent
commit
51e9c6525a
1 ha cambiato i file con 5 aggiunte e 2 eliminazioni
  1. 5 2
      gui/wxpython/gui_modules/gselect.py

+ 5 - 2
gui/wxpython/gui_modules/gselect.py

@@ -125,8 +125,11 @@ class TreeCtrlComboPopup(wx.combo.ComboPopup):
             if not root:
                 return
             item = self.FindItem(root, self.value[0])
-            self.seltree.EnsureVisible(item)
-            self.seltree.SelectItem(item)
+            try:
+                self.seltree.EnsureVisible(item)
+                self.seltree.SelectItem(item)
+            except:
+                pass
             
     def SetStringValue(self, value):
         # this assumes that item strings are unique...