Kaynağa Gözat

wxGUI/gselect: trying to fix keyboard navigation in map selection widget (merge from trunk, https://trac.osgeo.org/grass/changeset/63283, https://trac.osgeo.org/grass/changeset/63287)

git-svn-id: https://svn.osgeo.org/grass/grass/branches/releasebranch_7_0@63288 15284696-431f-4ddb-bdfa-cd5b030d7da7
Anna Petrášová 10 yıl önce
ebeveyn
işleme
64c861d241
1 değiştirilmiş dosya ile 4 ekleme ve 1 silme
  1. 4 1
      gui/wxpython/gui_core/gselect.py

+ 4 - 1
gui/wxpython/gui_core/gselect.py

@@ -111,7 +111,10 @@ class Select(wx.combo.ComboCtrl):
     def OnKeyDown(self, event):
         """Open popup and send key events to the tree."""
         if self.IsPopupShown():
-            self.tcp.OnKeyDown(event)
+            # on some configurations we get key down, with some only key up
+            # so we are trying to catch either key up or down
+            # this mess shouldn't be necessary with wxPython 3
+            self.tcp.OnKeyUp(event)
         else:
             if event.GetKeyCode() == wx.WXK_DOWN:
                 self.ShowPopup()