Commit 2758f05a authored by Eike Ziller's avatar Eike Ziller
Browse files

BaseFileFind: Fix crash when running search

Make sure we set a current search engine.
Regression introduced by 57ca90b8



Task-number: QTCREATORBUG-17346
Change-Id: Ia65971411e70124b0ea78cfe06597e34a6416af6
Reviewed-by: David Schulz's avatarDavid Schulz <david.schulz@qt.io>
parent 7b3642cc
......@@ -289,6 +289,8 @@ void BaseFileFind::replaceAll(const QString &txt, FindFlags findFlags)
void BaseFileFind::addSearchEngine(SearchEngine *searchEngine)
{
d->m_searchEngines.push_back(searchEngine);
if (d->m_searchEngines.size() == 1) // empty before, make sure we have a current engine
setCurrentSearchEngine(0);
}
void BaseFileFind::doReplace(const QString &text,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment