Do not trigger completion on up/down arrow keys

This commit is contained in:
Kovid Goyal 2014-12-29 12:27:45 +05:30
parent 5bcd936470
commit b30441093a

View File

@ -793,7 +793,9 @@ class TextEdit(PlainTextEdit):
if code in ( if code in (
0, Qt.Key_unknown, Qt.Key_Shift, Qt.Key_Control, Qt.Key_Alt, 0, Qt.Key_unknown, Qt.Key_Shift, Qt.Key_Control, Qt.Key_Alt,
Qt.Key_Meta, Qt.Key_AltGr, Qt.Key_CapsLock, Qt.Key_NumLock, Qt.Key_Meta, Qt.Key_AltGr, Qt.Key_CapsLock, Qt.Key_NumLock,
Qt.Key_ScrollLock): Qt.Key_ScrollLock, Qt.Key_Up, Qt.Key_Down):
# We ignore up/down arrow so as to not break scrolling through the
# text with the arrow keys
return return
result = self.smarts.get_completion_data(self, ev) result = self.smarts.get_completion_data(self, ev)
if result is None: if result is None: