mirror of
https://invent.kde.org/network/falkon.git
synced 2024-12-19 10:16:34 +01:00
Preferences: Fix editing per site user agent
Signed-off-by: Juraj Oravec <jurajoravec@mailo.com>
This commit is contained in:
parent
fcb3e06379
commit
322a23c0cf
@ -44,8 +44,9 @@ void UserAgentManager::loadSettings()
|
||||
QStringList userAgentsList = settings.value(QSL("UserAgentsList"), QStringList()).toStringList();
|
||||
settings.endGroup();
|
||||
|
||||
m_usePerDomainUserAgent = (m_usePerDomainUserAgent && domainList.count() == userAgentsList.count());
|
||||
m_usePerDomainUserAgent = (m_usePerDomainUserAgent && (domainList.count() == userAgentsList.count()));
|
||||
|
||||
m_userAgentsList.clear();
|
||||
if (m_usePerDomainUserAgent) {
|
||||
for (int i = 0; i < domainList.count(); ++i) {
|
||||
m_userAgentsList[domainList.at(i)] = userAgentsList.at(i);
|
||||
|
@ -176,6 +176,7 @@ void UserAgentDialog::accept()
|
||||
settings.setValue(QSL("DomainList"), domainList);
|
||||
settings.setValue(QSL("UserAgentsList"), userAgentsList);
|
||||
settings.endGroup();
|
||||
settings.sync();
|
||||
|
||||
m_manager->loadSettings();
|
||||
mApp->networkManager()->loadSettings();
|
||||
|
Loading…
Reference in New Issue
Block a user