Allow to use proxy per subsystem

This commit is contained in:
Vladimir Golovnev (Glassez) 2023-01-28 20:40:38 +03:00
parent 4745a40f0b
commit 6ac14d0c57
No known key found for this signature in database
GPG key ID: 52A2C7DEE2DFA6F7
23 changed files with 357 additions and 339 deletions

View file

@ -1619,6 +1619,37 @@ void Preferences::setNetworkCookies(const QList<QNetworkCookie> &cookies)
setValue(u"Network/Cookies"_qs, rawCookies);
}
bool Preferences::useProxyForBT() const
{
return value<bool>(u"Network/Proxy/Profiles/BitTorrent"_qs);
}
void Preferences::setUseProxyForBT(const bool value)
{
setValue(u"Network/Proxy/Profiles/BitTorrent"_qs, value);
}
bool Preferences::useProxyForRSS() const
{
return value<bool>(u"Network/Proxy/Profiles/RSS"_qs);
}
void Preferences::setUseProxyForRSS(const bool value)
{
setValue(u"Network/Proxy/Profiles/RSS"_qs, value);
}
bool Preferences::useProxyForGeneralPurposes() const
{
return value<bool>(u"Network/Proxy/Profiles/Misc"_qs);
}
void Preferences::setUseProxyForGeneralPurposes(const bool value)
{
setValue(u"Network/Proxy/Profiles/Misc"_qs, value);
}
bool Preferences::isSpeedWidgetEnabled() const
{
return value(u"SpeedWidget/Enabled"_qs, true);