mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Dont popup completion when pressing modifier keys
This commit is contained in:
parent
09bb6a6933
commit
d8c1c4b575
@ -786,6 +786,12 @@ class TextEdit(PlainTextEdit):
|
||||
def handle_keypress_completion(self, ev):
|
||||
if self.request_completion is None:
|
||||
return
|
||||
code = ev.key()
|
||||
if code in (
|
||||
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_ScrollLock):
|
||||
return
|
||||
result = self.smarts.get_completion_data(self, ev)
|
||||
if result is None:
|
||||
self.last_completion_request += 1
|
||||
|
Loading…
x
Reference in New Issue
Block a user