mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2024-11-29 13:58:51 +03:00
Merge pull request #1676 from sorokin/fix-open-file
fix issue #1674: AddNewTorrentDialog is shown again and again even if checkbox "dont ask me again" is set
This commit is contained in:
commit
5dea64ca16
1 changed files with 1 additions and 2 deletions
|
@ -931,10 +931,9 @@ void MainWindow::on_actionOpen_triggered() {
|
||||||
tr("Open Torrent Files"), settings.value(QString::fromUtf8("MainWindowLastDir"), QDir::homePath()).toString(),
|
tr("Open Torrent Files"), settings.value(QString::fromUtf8("MainWindowLastDir"), QDir::homePath()).toString(),
|
||||||
tr("Torrent Files")+QString::fromUtf8(" (*.torrent)"));
|
tr("Torrent Files")+QString::fromUtf8(" (*.torrent)"));
|
||||||
if (!pathsList.empty()) {
|
if (!pathsList.empty()) {
|
||||||
const bool useTorrentAdditionDialog = pref.useAdditionDialog();
|
|
||||||
const uint listSize = pathsList.size();
|
const uint listSize = pathsList.size();
|
||||||
for (uint i=0; i<listSize; ++i) {
|
for (uint i=0; i<listSize; ++i) {
|
||||||
if (useTorrentAdditionDialog)
|
if (pref.useAdditionDialog())
|
||||||
AddNewTorrentDialog::showTorrent(pathsList.at(i));
|
AddNewTorrentDialog::showTorrent(pathsList.at(i));
|
||||||
else
|
else
|
||||||
QBtSession::instance()->addTorrent(pathsList.at(i));
|
QBtSession::instance()->addTorrent(pathsList.at(i));
|
||||||
|
|
Loading…
Reference in a new issue