mirror of
https://github.com/d47081/qBittorrent.git
synced 2025-01-10 23:07:59 +00:00
Focus save path when Manual mode is selected initially
Closes #15972. PR #16536.
This commit is contained in:
parent
116664285d
commit
2c8447853b
@ -249,7 +249,11 @@ AddNewTorrentDialog::AddNewTorrentDialog(const BitTorrent::AddTorrentParams &inP
|
||||
connect(editHotkey, &QShortcut::activated, this, &AddNewTorrentDialog::renameSelectedFile);
|
||||
connect(m_ui->contentTreeView, &QAbstractItemView::doubleClicked, this, &AddNewTorrentDialog::renameSelectedFile);
|
||||
|
||||
m_ui->buttonBox->button(QDialogButtonBox::Ok)->setFocus();
|
||||
// Default focus
|
||||
if (m_ui->comboTTM->currentIndex() == 0) // 0 is Manual mode
|
||||
m_ui->savePath->setFocus();
|
||||
else
|
||||
m_ui->categoryComboBox->setFocus();
|
||||
}
|
||||
|
||||
AddNewTorrentDialog::~AddNewTorrentDialog()
|
||||
|
@ -189,6 +189,7 @@ FileSystemPathEdit::FileSystemPathEdit(Private::FileEditorWithCompletion *editor
|
||||
{
|
||||
Q_D(FileSystemPathEdit);
|
||||
editor->widget()->setParent(this);
|
||||
setFocusProxy(editor->widget());
|
||||
|
||||
auto *layout = new QHBoxLayout(this);
|
||||
layout->setContentsMargins(0, 0, 0, 0);
|
||||
|
@ -87,7 +87,11 @@ WatchedFolderOptionsDialog::WatchedFolderOptionsDialog(
|
||||
|
||||
loadState();
|
||||
|
||||
m_ui->buttonBox->button(QDialogButtonBox::Ok)->setFocus();
|
||||
// Default focus
|
||||
if (m_ui->comboTTM->currentIndex() == 0) // 0 is Manual mode
|
||||
m_ui->savePath->setFocus();
|
||||
else
|
||||
m_ui->categoryComboBox->setFocus();
|
||||
}
|
||||
|
||||
WatchedFolderOptionsDialog::~WatchedFolderOptionsDialog()
|
||||
|
Loading…
Reference in New Issue
Block a user