mirror of
https://invent.kde.org/network/falkon.git
synced 2024-12-20 18:56:34 +01:00
Fixed selecting search engine when using shortcuts in locationbar
It is now returning invalid engine when shortcut is empty
This commit is contained in:
parent
2ef2553167
commit
06b73291f3
@ -71,13 +71,18 @@ void SearchEnginesManager::loadSettings()
|
||||
|
||||
SearchEngine SearchEnginesManager::engineForShortcut(const QString &shortcut)
|
||||
{
|
||||
Engine returnEngine;
|
||||
if (shortcut.isEmpty())
|
||||
return returnEngine;
|
||||
|
||||
foreach(Engine en, m_allEngines) {
|
||||
if (en.shortcut == shortcut) {
|
||||
return en;
|
||||
returnEngine = en;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return Engine();
|
||||
return returnEngine;
|
||||
}
|
||||
|
||||
QUrl SearchEnginesManager::searchUrl(const Engine &engine, const QString &string)
|
||||
|
Loading…
Reference in New Issue
Block a user