瀏覽代碼

wxGUI/prompt: fix browsing command history on Windows

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@61102 15284696-431f-4ddb-bdfa-cd5b030d7da7
Anna Petrášová 11 年之前
父節點
當前提交
5708cfcb8e
共有 1 個文件被更改,包括 2 次插入1 次删除
  1. 2 1
      gui/wxpython/gui_core/prompt.py

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

@@ -416,7 +416,8 @@ class GPromptSTC(GPrompt, wx.stc.StyledTextCtrl):
                 self.cmdindex = len(self.cmdbuffer) - 1
                 self.cmdindex = len(self.cmdbuffer) - 1
 
 
             try:
             try:
-                txt = self.cmdbuffer[self.cmdindex]
+                # without strip causes problem on windows
+                txt = self.cmdbuffer[self.cmdindex].strip()
             except KeyError:
             except KeyError:
                 txt = ''
                 txt = ''