mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-07-11 15:56:17 -07:00
Expand the scope of "Proxy hostname lookup" option
This commit is contained in:
parent
6ac14d0c57
commit
96da685e5d
11 changed files with 57 additions and 61 deletions
|
@ -495,7 +495,6 @@ SessionImpl::SessionImpl(QObject *parent)
|
|||
, m_encryption(BITTORRENT_SESSION_KEY(u"Encryption"_qs), 0)
|
||||
, m_maxActiveCheckingTorrents(BITTORRENT_SESSION_KEY(u"MaxActiveCheckingTorrents"_qs), 1)
|
||||
, m_isProxyPeerConnectionsEnabled(BITTORRENT_SESSION_KEY(u"ProxyPeerConnections"_qs), false)
|
||||
, m_isProxyHostnameLookupEnabled(BITTORRENT_SESSION_KEY(u"ProxyHostnameLookup"_qs), true)
|
||||
, m_chokingAlgorithm(BITTORRENT_SESSION_KEY(u"ChokingAlgorithm"_qs), ChokingAlgorithm::FixedSlots
|
||||
, clampValue(ChokingAlgorithm::FixedSlots, ChokingAlgorithm::RateBased))
|
||||
, m_seedChokingAlgorithm(BITTORRENT_SESSION_KEY(u"SeedChokingAlgorithm"_qs), SeedChokingAlgorithm::FastestUpload
|
||||
|
@ -1669,7 +1668,7 @@ lt::settings_pack SessionImpl::loadLTSettings() const
|
|||
}
|
||||
|
||||
settingsPack.set_bool(lt::settings_pack::proxy_peer_connections, isProxyPeerConnectionsEnabled());
|
||||
settingsPack.set_bool(lt::settings_pack::proxy_hostnames, isProxyHostnameLookupEnabled());
|
||||
settingsPack.set_bool(lt::settings_pack::proxy_hostnames, proxyConfig.hostnameLookupEnabled);
|
||||
}
|
||||
|
||||
settingsPack.set_bool(lt::settings_pack::announce_to_all_trackers, announceToAllTrackers());
|
||||
|
@ -3545,20 +3544,6 @@ void SessionImpl::setProxyPeerConnectionsEnabled(const bool enabled)
|
|||
}
|
||||
}
|
||||
|
||||
bool SessionImpl::isProxyHostnameLookupEnabled() const
|
||||
{
|
||||
return m_isProxyHostnameLookupEnabled;
|
||||
}
|
||||
|
||||
void SessionImpl::setProxyHostnameLookupEnabled(const bool enabled)
|
||||
{
|
||||
if (enabled != isProxyHostnameLookupEnabled())
|
||||
{
|
||||
m_isProxyHostnameLookupEnabled = enabled;
|
||||
configureDeferred();
|
||||
}
|
||||
}
|
||||
|
||||
ChokingAlgorithm SessionImpl::chokingAlgorithm() const
|
||||
{
|
||||
return m_chokingAlgorithm;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue