forked from qt-creator/qt-creator
FakeVim: Don't filter events recursively
Task-number: QTCREATORBUG-10226 Change-Id: Ic5fdb125cfce603c24e8c88cbcd43f13e8af9d06 Reviewed-by: hjk <hjk121@nokiamail.com>
This commit is contained in:
@@ -2100,9 +2100,6 @@ void FakeVimHandler::Private::init()
|
||||
|
||||
void FakeVimHandler::Private::focus()
|
||||
{
|
||||
if (g.inFakeVim)
|
||||
return;
|
||||
|
||||
enterFakeVim();
|
||||
|
||||
stopIncrementalFind();
|
||||
@@ -2135,6 +2132,8 @@ void FakeVimHandler::Private::enterFakeVim()
|
||||
m_cursor = EDITOR(textCursor());
|
||||
g.inFakeVim = true;
|
||||
|
||||
removeEventFilter();
|
||||
|
||||
updateFirstVisibleLine();
|
||||
importSelection();
|
||||
|
||||
@@ -2186,6 +2185,8 @@ void FakeVimHandler::Private::leaveFakeVim(bool needUpdate)
|
||||
scrollToLine(firstVisibleLine());
|
||||
updateScrollOffset();
|
||||
}
|
||||
|
||||
installEventFilter();
|
||||
}
|
||||
|
||||
g.inFakeVim = false;
|
||||
|
||||
Reference in New Issue
Block a user