summary refs log tree commit diff
path: root/src/TextInputWidget.cc
diff options
context:
space:
mode:
authorKonstantinos Sideris <sideris.konstantin@gmail.com>2018-07-15 21:26:48 +0300
committerKonstantinos Sideris <sideris.konstantin@gmail.com>2018-07-15 21:26:48 +0300
commit21185a44e723d016246af1b03a24ac787790106e (patch)
tree18ea3992c7d0266f52cb6b7980599a4a1b30651c /src/TextInputWidget.cc
parentUse MainWindow instead of QApplication::activeWindow to reference the main wi... (diff)
downloadnheko-21185a44e723d016246af1b03a24ac787790106e.tar.xz
Properly reset the autocomplete anchor when the popup closes
fixes #305
Diffstat (limited to 'src/TextInputWidget.cc')
-rw-r--r--src/TextInputWidget.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/TextInputWidget.cc b/src/TextInputWidget.cc

index 7ee7fa16..bb72c533 100644 --- a/src/TextInputWidget.cc +++ b/src/TextInputWidget.cc
@@ -217,6 +217,7 @@ FilteredTextEdit::keyPressEvent(QKeyEvent *event) auto word = cursor.selectedText(); if (cursor.position() == 0) { + resetAnchor(); closeSuggestions(); return; } @@ -231,6 +232,7 @@ FilteredTextEdit::keyPressEvent(QKeyEvent *event) emit showSuggestions(query()); } else { + resetAnchor(); closeSuggestions(); }