mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-07-10 15:32:48 -07:00
parent
7faa8b7a02
commit
d1515456bc
8 changed files with 83 additions and 30 deletions
|
@ -375,6 +375,7 @@ OptionsDialog::OptionsDialog(QWidget *parent)
|
|||
connect(m_ui->checkUseDownloadPath, &QAbstractButton::toggled, this, &ThisType::enableApplyButton);
|
||||
connect(m_ui->checkUseDownloadPath, &QAbstractButton::toggled, m_ui->textDownloadPath, &QWidget::setEnabled);
|
||||
connect(m_ui->addWatchedFolderButton, &QAbstractButton::clicked, this, &ThisType::enableApplyButton);
|
||||
connect(m_ui->groupExcludedFileNames, &QGroupBox::toggled, this, &ThisType::enableApplyButton);
|
||||
connect(m_ui->textExcludedFileNames, &QPlainTextEdit::textChanged, this, &ThisType::enableApplyButton);
|
||||
connect(m_ui->removeWatchedFolderButton, &QAbstractButton::clicked, this, &ThisType::enableApplyButton);
|
||||
connect(m_ui->groupMailNotification, &QGroupBox::toggled, this, &ThisType::enableApplyButton);
|
||||
|
@ -758,6 +759,7 @@ void OptionsDialog::saveOptions()
|
|||
session->setTorrentContentLayout(static_cast<BitTorrent::TorrentContentLayout>(m_ui->contentLayoutComboBox->currentIndex()));
|
||||
auto watchedFoldersModel = static_cast<WatchedFoldersModel *>(m_ui->scanFoldersView->model());
|
||||
watchedFoldersModel->apply();
|
||||
session->setExcludedFileNamesEnabled(m_ui->groupExcludedFileNames->isChecked());
|
||||
session->setExcludedFileNames(m_ui->textExcludedFileNames->toPlainText().split(u'\n', Qt::SkipEmptyParts));
|
||||
session->setTorrentExportDirectory(getTorrentExportDir());
|
||||
session->setFinishedTorrentExportDirectory(getFinishedTorrentExportDir());
|
||||
|
@ -1018,6 +1020,7 @@ void OptionsDialog::loadOptions()
|
|||
m_ui->checkAppendqB->setChecked(session->isAppendExtensionEnabled());
|
||||
m_ui->checkPreallocateAll->setChecked(session->isPreallocationEnabled());
|
||||
m_ui->checkRecursiveDownload->setChecked(!pref->recursiveDownloadDisabled());
|
||||
m_ui->groupExcludedFileNames->setChecked(session->isExcludedFileNamesEnabled());
|
||||
m_ui->textExcludedFileNames->setPlainText(session->excludedFileNames().join(u'\n'));
|
||||
|
||||
if (session->torrentExportDirectory().isEmpty())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue