Allow to set torrent stop condition

PR #17814.

Closes #17792.
Closes #929.

(Actually it should close all issues about lack of ability to stop torrent after metadata downloaded or after files are initially checked.)

Also makes explicit the temporary start of the torrent in the case when recheck of the stopped torrent is performed.
This commit is contained in:
Vladimir Golovnev 2022-10-09 16:07:16 +03:00 committed by GitHub
commit 67357e9964
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
19 changed files with 295 additions and 87 deletions

View file

@ -188,6 +188,8 @@ namespace BitTorrent
void setPeXEnabled(bool enabled) override;
bool isAddTorrentPaused() const override;
void setAddTorrentPaused(bool value) override;
Torrent::StopCondition torrentStopCondition() const override;
void setTorrentStopCondition(Torrent::StopCondition stopCondition) override;
TorrentContentLayout torrentContentLayout() const override;
void setTorrentContentLayout(TorrentContentLayout value) override;
bool isTrackerEnabled() const override;
@ -620,6 +622,7 @@ namespace BitTorrent
CachedSettingValue<qreal> m_globalMaxRatio;
CachedSettingValue<int> m_globalMaxSeedingMinutes;
CachedSettingValue<bool> m_isAddTorrentPaused;
CachedSettingValue<Torrent::StopCondition> m_torrentStopCondition;
CachedSettingValue<TorrentContentLayout> m_torrentContentLayout;
CachedSettingValue<bool> m_isAppendExtensionEnabled;
CachedSettingValue<int> m_refreshInterval;