浏览代码

wxGUI/prompt: reacting to - (minus) key in all cases in command console (relates to https://trac.osgeo.org/grass/ticket/2152)

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@58788 15284696-431f-4ddb-bdfa-cd5b030d7da7
Vaclav Petras 11 年之前
父节点
当前提交
98dbbfb347
共有 1 个文件被更改,包括 4 次插入2 次删除
  1. 4 2
      gui/wxpython/gui_core/prompt.py

+ 4 - 2
gui/wxpython/gui_core/prompt.py

@@ -404,8 +404,10 @@ class GPromptSTC(GPrompt, wx.stc.StyledTextCtrl):
                 return
                 return
             self.ShowList()
             self.ShowList()
 
 
-        # complete flags after pressing '-'       
-        elif event.GetKeyCode() == 45 and not event.ShiftDown(): 
+        # complete flags after pressing '-'
+        elif (event.GetKeyCode() == 45 and not event.ShiftDown()) \
+                or event.GetKeyCode() == wx.WXK_NUMPAD_SUBTRACT \
+                or event.GetKeyCode() == wx.WXK_SUBTRACT:
             self.autoCompList = list()
             self.autoCompList = list()
             entry = self.GetTextLeft()
             entry = self.GetTextLeft()
             self.InsertText(pos, '-')
             self.InsertText(pos, '-')