mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2026-01-05 07:02:31 -06:00
BUGFIX: Really disable torrent addition dialog by default
This commit is contained in:
@@ -1,3 +1,6 @@
|
|||||||
|
* Unreleased - Christophe Dumez <chris@qbittorrent.org> - v2.6.1
|
||||||
|
- BUGFIX: Really disable torrent addition dialog by default
|
||||||
|
|
||||||
* Sun Jan 9 2011 - Christophe Dumez <chris@qbittorrent.org> - v2.6.0
|
* Sun Jan 9 2011 - Christophe Dumez <chris@qbittorrent.org> - v2.6.0
|
||||||
- FEATURE: Use system icons (Linux, Qt >= 4.6)
|
- FEATURE: Use system icons (Linux, Qt >= 4.6)
|
||||||
- FEATURE: Improved ETA calculation
|
- FEATURE: Improved ETA calculation
|
||||||
|
|||||||
@@ -804,8 +804,8 @@ void MainWindow::dropEvent(QDropEvent *event) {
|
|||||||
files = event->mimeData()->text().split(QString::fromUtf8("\n"));
|
files = event->mimeData()->text().split(QString::fromUtf8("\n"));
|
||||||
}
|
}
|
||||||
// Add file to download list
|
// Add file to download list
|
||||||
QIniSettings settings(QString::fromUtf8("qBittorrent"), QString::fromUtf8("qBittorrent"));
|
Preferences pref;
|
||||||
const bool useTorrentAdditionDialog = settings.value(QString::fromUtf8("Preferences/Downloads/AdditionDialog"), true).toBool();
|
const bool useTorrentAdditionDialog = pref.useAdditionDialog();
|
||||||
foreach(QString file, files) {
|
foreach(QString file, files) {
|
||||||
qDebug("Dropped file %s on download list", qPrintable(file));
|
qDebug("Dropped file %s on download list", qPrintable(file));
|
||||||
if(misc::isUrl(file)) {
|
if(misc::isUrl(file)) {
|
||||||
@@ -857,6 +857,7 @@ void MainWindow::dragEnterEvent(QDragEnterEvent *event) {
|
|||||||
// Display a dialog to allow user to add
|
// Display a dialog to allow user to add
|
||||||
// torrents to download list
|
// torrents to download list
|
||||||
void MainWindow::on_actionOpen_triggered() {
|
void MainWindow::on_actionOpen_triggered() {
|
||||||
|
Preferences pref;
|
||||||
QIniSettings settings(QString::fromUtf8("qBittorrent"), QString::fromUtf8("qBittorrent"));
|
QIniSettings settings(QString::fromUtf8("qBittorrent"), QString::fromUtf8("qBittorrent"));
|
||||||
// Open File Open Dialog
|
// Open File Open Dialog
|
||||||
// Note: it is possible to select more than one file
|
// Note: it is possible to select more than one file
|
||||||
@@ -864,7 +865,7 @@ 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 = settings.value(QString::fromUtf8("Preferences/Downloads/AdditionDialog"), true).toBool();
|
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(useTorrentAdditionDialog) {
|
||||||
|
|||||||
Reference in New Issue
Block a user