aboutsummaryrefslogtreecommitdiff
path: root/src/webengine/webprofile.cpp
diff options
context:
space:
mode:
authorAqua-sama <aqua@iserlohn-fortress.net>2018-04-17 11:12:44 +0200
committerAqua-sama <aqua@iserlohn-fortress.net>2018-04-17 11:12:44 +0200
commite78d3cc07f4b29518c4ebe15e3ab56c73c4cace5 (patch)
tree9c64aa396fcca4ba87b7fa05de13546d9c4c27a4 /src/webengine/webprofile.cpp
parentEnabled address bar suggestions (diff)
downloadsmolbote-e78d3cc07f4b29518c4ebe15e3ab56c73c4cace5.tar.xz
Address bar searches work again
Diffstat (limited to 'src/webengine/webprofile.cpp')
-rw-r--r--src/webengine/webprofile.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/webengine/webprofile.cpp b/src/webengine/webprofile.cpp
index 24b23a0..54aab5a 100644
--- a/src/webengine/webprofile.cpp
+++ b/src/webengine/webprofile.cpp
@@ -53,15 +53,19 @@ QUrl WebProfile::newtab() const
return m_newtab;
}
-void WebProfile::loadProfile(QHash<QString, QString> conf, const QString &path)
+void WebProfile::loadProfile(QHash<QString, QString> conf)
{
- m_configPath = path;
+ if(isOffTheRecord())
+ m_configPath = conf.value("profile.path") + "/otr.ini";
+ else
+ m_configPath = conf.value("profile.path") + "/" + storageName() + "/profile.ini";
#ifdef QT_DEBUG
qDebug("Reading config for profile '%s': %s", qUtf8Printable(m_name), qUtf8Printable(m_configPath));
#endif
QSettings config(m_configPath, QSettings::IniFormat);
+ m_search = config.value("search", conf.value("profile.search")).toString();
m_homepage = config.value("homepage", conf["profile.homepage"]).toUrl();
m_newtab = config.value("newtab", conf["profile.newtab"]).toUrl();