fakevim: make find next/previous work with incremental search

Merge-request: 97
Reviewed-by: hjk <qtc-committer@nokia.com>
This commit is contained in:
Martin Aumüller
2010-01-21 17:23:29 +01:00
committed by hjk
parent 068ff3a188
commit 825d1c7932

View File

@@ -1511,13 +1511,19 @@ EventResult FakeVimHandler::Private::handleCommandMode(int key, int unmodified,
finishMovement();
} else if (key == 'n') { // FIXME: see comment for '/'
if (hasConfig(ConfigIncSearch))
{
emit q->findNextRequested(false);
m_tc = EDITOR(textCursor());
}
else
search(lastSearchString(), m_lastSearchForward);
recordJump();
} else if (key == 'N') {
if (hasConfig(ConfigIncSearch))
{
emit q->findNextRequested(true);
m_tc = EDITOR(textCursor());
}
else
search(lastSearchString(), !m_lastSearchForward);
recordJump();