1
mirror of https://invent.kde.org/network/falkon.git synced 2024-12-24 12:46:35 +01:00

[Fix] Fixed searching strings with & character.

This commit is contained in:
nowrep 2012-01-21 00:20:30 +01:00
parent b47c91db5f
commit 647487fcdb

View File

@ -92,18 +92,14 @@ QUrl SearchEnginesManager::searchUrl(const Engine &engine, const QString &string
{
ENSURE_LOADED;
QString url = engine.url;
url.replace("%s", string);
return QUrl(url);
QByteArray url = engine.url.toUtf8();
url.replace("%s", QUrl::toPercentEncoding(string));
return QUrl::fromEncoded(url);
}
QUrl SearchEnginesManager::searchUrl(const QString &string)
{
ENSURE_LOADED;
QString url = m_activeEngine.url;
url.replace("%s", string);
return QUrl(url);
return searchUrl(m_activeEngine, string);
}
void SearchEnginesManager::restoreDefaults()