Add seeding limits to RSS and Watched folders options UI

PR #20324.
Closes #19605.
This commit is contained in:
Vladimir Golovnev
2024-01-27 14:30:27 +03:00
committed by GitHub
parent df41940ebc
commit d652a10495
6 changed files with 450 additions and 2 deletions

View File

@@ -143,7 +143,12 @@ void AddTorrentParamsWidget::setAddTorrentParams(BitTorrent::AddTorrentParams ad
BitTorrent::AddTorrentParams AddTorrentParamsWidget::addTorrentParams() const
{
return cleanParams(m_addTorrentParams);
BitTorrent::AddTorrentParams addTorrentParams = cleanParams(m_addTorrentParams);
addTorrentParams.ratioLimit = m_ui->torrentShareLimitsWidget->ratioLimit();
addTorrentParams.seedingTimeLimit = m_ui->torrentShareLimitsWidget->seedingTimeLimit();
addTorrentParams.inactiveSeedingTimeLimit = m_ui->torrentShareLimitsWidget->inactiveSeedingTimeLimit();
return addTorrentParams;
}
void AddTorrentParamsWidget::populate()
@@ -263,6 +268,9 @@ void AddTorrentParamsWidget::populate()
else
m_addTorrentParams.addToQueueTop = data.toBool();
});
m_ui->torrentShareLimitsWidget->setTorrentShareLimits(m_addTorrentParams.ratioLimit
, m_addTorrentParams.seedingTimeLimit, m_addTorrentParams.inactiveSeedingTimeLimit);
}
void AddTorrentParamsWidget::loadCustomSavePathOptions()