mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-07-07 13:41:26 -07:00
Allow to remember torrent content files deletion in WebUI
Add a 'remember choice' button to the WebUI Torrent Deletion dialog that sets the default file deletion setting. The setting is shared with GUI, so if you set it in WebUI and open the Qt app, the 'delete files' checkbox will match WebUI (checked or unchecked). PR #20150. --------- Co-authored-by: Chocobo1 <Chocobo1@users.noreply.github.com>
This commit is contained in:
parent
0b6d785e87
commit
e69f857828
8 changed files with 81 additions and 11 deletions
|
@ -119,6 +119,8 @@ void AppController::preferencesAction()
|
|||
data[u"file_log_delete_old"_s] = app()->isFileLoggerDeleteOld();
|
||||
data[u"file_log_age"_s] = app()->fileLoggerAge();
|
||||
data[u"file_log_age_type"_s] = app()->fileLoggerAgeType();
|
||||
// Delete torrent contents files on torrent removal
|
||||
data[u"delete_torrent_content_files"_s] = pref->deleteTorrentFilesAsDefault();
|
||||
|
||||
// Downloads
|
||||
// When adding a torrent
|
||||
|
@ -494,6 +496,9 @@ void AppController::setPreferencesAction()
|
|||
app()->setFileLoggerAge(it.value().toInt());
|
||||
if (hasKey(u"file_log_age_type"_s))
|
||||
app()->setFileLoggerAgeType(it.value().toInt());
|
||||
// Delete torrent content files on torrent removal
|
||||
if (hasKey(u"delete_torrent_content_files"_s))
|
||||
pref->setDeleteTorrentFilesAsDefault(it.value().toBool());
|
||||
|
||||
// Downloads
|
||||
// When adding a torrent
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue