1
mirror of https://github.com/qbittorrent/qBittorrent synced 2025-11-02 08:10:54 +01:00

Compare commits

..

15 Commits

Author SHA1 Message Date
Christophe Dumez
e3f2d458d4 Tagged v2.3.1 release 2010-08-17 09:04:27 +00:00
Christophe Dumez
94f754000f Updated release date 2010-08-17 08:45:45 +00:00
Christophe Dumez
67c7d257a3 Bump to v2.3.1 2010-08-16 16:53:56 +00:00
Christophe Dumez
f6f62a01a9 Fix possible folder watching issues on Windows 2010-08-16 11:58:55 +00:00
Christophe Dumez
b759211af8 Fix to last commit 2010-08-16 09:25:58 +00:00
Christophe Dumez
26ce8ad19a Fix scanned path display on Windows and OS/2 2010-08-16 09:00:34 +00:00
Christophe Dumez
efa52b62b1 BUGFIX: Priority actions are only effective if the transfer list tab is displayed 2010-08-15 07:46:53 +00:00
Christophe Dumez
0144611b9d BUGFIX: Fix speed limit sliders initialization in Web UI 2010-08-15 07:41:30 +00:00
Christophe Dumez
9292fdc647 BUGFIX: Added missing right-click menu icon in Web UI 2010-08-15 07:25:43 +00:00
Christophe Dumez
064306af17 Updated resource files 2010-08-14 15:54:19 +00:00
Christophe Dumez
2401ae1d8a Remember previously selected paths in torrent creation dialog 2010-08-13 14:07:53 +00:00
Christophe Dumez
fc42449d3a Fix about dialog layout 2010-08-13 13:38:29 +00:00
Christophe Dumez
b651fcffa0 Fix compilation with gcc 4.5 2010-08-13 13:30:26 +00:00
Christophe Dumez
5ab38a9de8 Bump to v2.3.0 final 2010-07-27 08:12:03 +00:00
Christophe Dumez
2afed45400 branched v2.3.x 2010-07-27 08:03:38 +00:00
107 changed files with 5881 additions and 12250 deletions

View File

@@ -12,7 +12,7 @@ Contributors:
* Silvan Scherrer <silvan.scherrer@aroa.ch> * Silvan Scherrer <silvan.scherrer@aroa.ch>
Code from other projects: Code from other projects:
* files src/qtsingleapp/* src/lineedit/* * files src/qtsingleapp/*
copyright: Nokia Corporation copyright: Nokia Corporation
license: LGPL license: LGPL

View File

@@ -1,12 +1,11 @@
* Unreleased - Christophe Dumez <chris@qbittorrent.org> - v2.4.0 * Tue Aug 17 2010 - Christophe Dumez <chris@qbittorrent.org> - v2.3.1
- FEATURE: Added actions to "Move to top/bottom" of priority queue - BUGFIX: Fix compilation with gcc 4.5
- FEATURE: Auto-Shutdown on downloads completion - BUGFIX: Fix about dialog layout
- FEATURE: Email notification on download completion - BUGFIX: Remember previously selected paths in torrent creation dialog
- FEATURE: Added button to password-lock the UI - BUGFIX: Added missing right-click menu icon in Web UI
- FEATURE: Added label-level Pause/Resume/Delete actions - BUGFIX: Fix speed limit sliders initialization in Web UI
- FEATURE: Torrents can now be filtered by name - BUGFIX: Priority actions are only effective if the transfer list tab is displayed
- FEATURE: Run external program on torrent completion - BUGFIX: Fix possible folder watching issues on Windows and OS/2
- FEATURE: Detect executable updates in order to advise the user to restart
* Tue Jul 27 2010 - Christophe Dumez <chris@qbittorrent.org> - v2.3.0 * Tue Jul 27 2010 - Christophe Dumez <chris@qbittorrent.org> - v2.3.0
- FEATURE: Simplified torrent root folder renaming/truncating (< v2.3.0 is no longer forward compatible) - FEATURE: Simplified torrent root folder renaming/truncating (< v2.3.0 is no longer forward compatible)

View File

@@ -34,7 +34,6 @@
#endif #endif
#include <QFileDialog> #include <QFileDialog>
#include <QFileSystemWatcher>
#include <QMessageBox> #include <QMessageBox>
#include <QTimer> #include <QTimer>
#include <QDesktopServices> #include <QDesktopServices>
@@ -70,7 +69,6 @@
#include "qmacapplication.h" #include "qmacapplication.h"
void qt_mac_set_dock_menu(QMenu *menu); void qt_mac_set_dock_menu(QMenu *menu);
#endif #endif
#include "lineedit.h"
using namespace libtorrent; using namespace libtorrent;
@@ -85,7 +83,7 @@ using namespace libtorrent;
// Constructor // Constructor
GUI::GUI(QWidget *parent, QStringList torrentCmdLine) : QMainWindow(parent), force_exit(false) { GUI::GUI(QWidget *parent, QStringList torrentCmdLine) : QMainWindow(parent), force_exit(false) {
setupUi(this); setupUi(this);
ui_locked = Preferences::isUILocked();
setWindowTitle(tr("qBittorrent %1", "e.g: qBittorrent v0.x").arg(QString::fromUtf8(VERSION))); setWindowTitle(tr("qBittorrent %1", "e.g: qBittorrent v0.x").arg(QString::fromUtf8(VERSION)));
displaySpeedInTitle = Preferences::speedInTitleBar(); displaySpeedInTitle = Preferences::speedInTitleBar();
// Setting icons // Setting icons
@@ -109,11 +107,6 @@ GUI::GUI(QWidget *parent, QStringList torrentCmdLine) : QMainWindow(parent), for
actionSet_global_upload_limit->setIcon(QIcon(QString::fromUtf8(":/Icons/skin/seeding.png"))); actionSet_global_upload_limit->setIcon(QIcon(QString::fromUtf8(":/Icons/skin/seeding.png")));
actionSet_global_download_limit->setIcon(QIcon(QString::fromUtf8(":/Icons/skin/download.png"))); actionSet_global_download_limit->setIcon(QIcon(QString::fromUtf8(":/Icons/skin/download.png")));
actionDocumentation->setIcon(QIcon(QString::fromUtf8(":/Icons/skin/qb_question.png"))); actionDocumentation->setIcon(QIcon(QString::fromUtf8(":/Icons/skin/qb_question.png")));
actionLock_qBittorrent->setIcon(QIcon(QString::fromUtf8(":/Icons/oxygen/encrypted32.png")));
QMenu *lockMenu = new QMenu();
QAction *defineUiLockPasswdAct = lockMenu->addAction(tr("Set the password..."));
connect(defineUiLockPasswdAct, SIGNAL(triggered()), this, SLOT(defineUILockPassword()));
actionLock_qBittorrent->setMenu(lockMenu);
prioSeparator = toolBar->insertSeparator(actionDecreasePriority); prioSeparator = toolBar->insertSeparator(actionDecreasePriority);
prioSeparator2 = menu_Edit->insertSeparator(actionDecreasePriority); prioSeparator2 = menu_Edit->insertSeparator(actionDecreasePriority);
prioSeparator->setVisible(false); prioSeparator->setVisible(false);
@@ -156,13 +149,6 @@ GUI::GUI(QWidget *parent, QStringList torrentCmdLine) : QMainWindow(parent), for
connect(transferList, SIGNAL(torrentStatusUpdate(uint,uint,uint,uint,uint)), this, SLOT(updateNbTorrents(uint,uint,uint,uint,uint))); connect(transferList, SIGNAL(torrentStatusUpdate(uint,uint,uint,uint,uint)), this, SLOT(updateNbTorrents(uint,uint,uint,uint,uint)));
vboxLayout->addWidget(tabs); vboxLayout->addWidget(tabs);
// Name filter
search_filter = new LineEdit();
QAction *separatorBFSearch = toolBar->insertSeparator(actionLock_qBittorrent);
toolBar->insertWidget(separatorBFSearch, search_filter);
search_filter->setFixedWidth(200);
connect(search_filter, SIGNAL(textChanged(QString)), transferList, SLOT(applyNameFilter(QString)));
// Transfer list slots // Transfer list slots
connect(actionStart, SIGNAL(triggered()), transferList, SLOT(startSelectedTorrents())); connect(actionStart, SIGNAL(triggered()), transferList, SLOT(startSelectedTorrents()));
connect(actionStart_All, SIGNAL(triggered()), transferList, SLOT(startAllTorrents())); connect(actionStart_All, SIGNAL(triggered()), transferList, SLOT(startAllTorrents()));
@@ -174,6 +160,10 @@ GUI::GUI(QWidget *parent, QStringList torrentCmdLine) : QMainWindow(parent), for
// Configure BT session according to options // Configure BT session according to options
loadPreferences(false); loadPreferences(false);
// Resume unfinished torrents
BTSession->startUpTorrents();
// Add torrent given on command line
processParams(torrentCmdLine);
// Start connection checking timer // Start connection checking timer
guiUpdater = new QTimer(this); guiUpdater = new QTimer(this);
@@ -197,7 +187,6 @@ GUI::GUI(QWidget *parent, QStringList torrentCmdLine) : QMainWindow(parent), for
actionSearch_engine->setChecked(Preferences::isSearchEnabled()); actionSearch_engine->setChecked(Preferences::isSearchEnabled());
displaySearchTab(actionSearch_engine->isChecked()); displaySearchTab(actionSearch_engine->isChecked());
displayRSSTab(actionRSS_Reader->isChecked()); displayRSSTab(actionRSS_Reader->isChecked());
actionShutdown_when_downloads_complete->setChecked(Preferences::shutdownWhenDownloadsComplete());
show(); show();
@@ -214,23 +203,10 @@ GUI::GUI(QWidget *parent, QStringList torrentCmdLine) : QMainWindow(parent), for
}while(transferListFilters->getStatusFilters()->verticalScrollBar()->sliderPosition() > 0); }while(transferListFilters->getStatusFilters()->verticalScrollBar()->sliderPosition() > 0);
transferListFilters->getStatusFilters()->setVerticalScrollBarPolicy(Qt::ScrollBarAlwaysOff); transferListFilters->getStatusFilters()->setVerticalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
if(ui_locked) { if(Preferences::startMinimized()) {
hide(); showMinimized();
} else {
if(Preferences::startMinimized())
showMinimized();
} }
// Start watching the executable for updates
executable_watcher = new QFileSystemWatcher();
connect(executable_watcher, SIGNAL(fileChanged(QString)), this, SLOT(notifyOfUpdate(QString)));
executable_watcher->addPath(qApp->applicationFilePath());
// Resume unfinished torrents
BTSession->startUpTorrents();
// Add torrent given on command line
processParams(torrentCmdLine);
qDebug("GUI Built"); qDebug("GUI Built");
#ifdef Q_WS_WIN #ifdef Q_WS_WIN
if(!Preferences::neverCheckFileAssoc() && !Preferences::isFileAssocOk()) { if(!Preferences::neverCheckFileAssoc() && !Preferences::isFileAssocOk()) {
@@ -263,10 +239,7 @@ GUI::~GUI() {
properties->saveSettings(); properties->saveSettings();
disconnect(tabs, SIGNAL(currentChanged(int)), this, SLOT(tab_changed(int))); disconnect(tabs, SIGNAL(currentChanged(int)), this, SLOT(tab_changed(int)));
// Delete other GUI objects // Delete other GUI objects
if(executable_watcher)
delete executable_watcher;
delete status_bar; delete status_bar;
delete search_filter;
delete transferList; delete transferList;
delete guiUpdater; delete guiUpdater;
if(createTorrentDlg) if(createTorrentDlg)
@@ -303,8 +276,10 @@ GUI::~GUI() {
delete switchTransferShortcut; delete switchTransferShortcut;
delete switchRSSShortcut; delete switchRSSShortcut;
// Delete BTSession objects // Delete BTSession objects
qDebug("Deleting BTSession");
delete BTSession; delete BTSession;
// Deleting remaining top level widgets
qDebug("Deleting remaining top level widgets");
// May freeze for a few seconds after the next line // May freeze for a few seconds after the next line
// because the Bittorrent session proxy will // because the Bittorrent session proxy will
// actually be deleted now and destruction // actually be deleted now and destruction
@@ -312,35 +287,6 @@ GUI::~GUI() {
qDebug("Exiting GUI destructor..."); qDebug("Exiting GUI destructor...");
} }
void GUI::defineUILockPassword() {
QString old_pass_md5 = Preferences::getUILockPasswordMD5();
if(old_pass_md5.isNull()) old_pass_md5 = "";
bool ok = false;
QString new_clear_password = QInputDialog::getText(this, tr("UI lock password"), tr("Please type the UI lock password:"), QLineEdit::Password, old_pass_md5, &ok);
if(ok) {
if(new_clear_password != old_pass_md5) {
Preferences::setUILockPassword(new_clear_password);
}
QMessageBox::information(this, tr("Password update"), tr("The UI lock password has been successfully updated"));
}
}
void GUI::on_actionLock_qBittorrent_triggered() {
// Check if there is a password
if(Preferences::getUILockPasswordMD5().isEmpty()) {
// Ask for a password
bool ok = false;
QString clear_password = QInputDialog::getText(this, tr("UI lock password"), tr("Please type the UI lock password:"), QLineEdit::Password, "", &ok);
if(!ok) return;
Preferences::setUILockPassword(clear_password);
}
// Lock the interface
ui_locked = true;
Preferences::setUILocked(true);
myTrayIconMenu->setEnabled(false);
hide();
}
void GUI::displayRSSTab(bool enable) { void GUI::displayRSSTab(bool enable) {
if(enable) { if(enable) {
// RSS tab // RSS tab
@@ -582,41 +528,10 @@ void GUI::setTabText(int index, QString text) const {
tabs->setTabText(index, text); tabs->setTabText(index, text);
} }
bool GUI::unlockUI() {
bool ok = false;
QString clear_password = QInputDialog::getText(this, tr("UI lock password"), tr("Please type the UI lock password:"), QLineEdit::Password, "", &ok);
if(!ok) return false;
QString real_pass_md5 = Preferences::getUILockPasswordMD5();
QCryptographicHash md5(QCryptographicHash::Md5);
md5.addData(clear_password.toLocal8Bit());
QString password_md5 = md5.result().toHex();
if(real_pass_md5 == password_md5) {
ui_locked = false;
Preferences::setUILocked(false);
myTrayIconMenu->setEnabled(true);
return true;
}
QMessageBox::warning(this, tr("Invalid password"), tr("The password is invalid"));
return false;
}
void GUI::notifyOfUpdate(QString) {
// Show restart message
status_bar->showRestartRequired();
// Delete the executable watcher
delete executable_watcher;
executable_watcher = 0;
}
// Toggle Main window visibility // Toggle Main window visibility
void GUI::toggleVisibility(QSystemTrayIcon::ActivationReason e) { void GUI::toggleVisibility(QSystemTrayIcon::ActivationReason e) {
if(e == QSystemTrayIcon::Trigger || e == QSystemTrayIcon::DoubleClick) { if(e == QSystemTrayIcon::Trigger || e == QSystemTrayIcon::DoubleClick) {
if(isHidden()) { if(isHidden()) {
if(ui_locked) {
// Ask for UI lock password
if(!unlockUI())
return;
}
show(); show();
if(isMinimized()) { if(isMinimized()) {
if(isMaximized()) { if(isMaximized()) {
@@ -823,8 +738,8 @@ void GUI::on_actionOpen_triggered() {
// 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
const QStringList pathsList = QFileDialog::getOpenFileNames(0, const QStringList pathsList = QFileDialog::getOpenFileNames(0,
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 = settings.value(QString::fromUtf8("Preferences/Downloads/AdditionDialog"), true).toBool();
const uint listSize = pathsList.size(); const uint listSize = pathsList.size();
@@ -906,7 +821,6 @@ void GUI::loadPreferences(bool configure_session) {
BTSession->addConsoleMessage(tr("Options were saved successfully.")); BTSession->addConsoleMessage(tr("Options were saved successfully."));
#ifndef Q_WS_MAC #ifndef Q_WS_MAC
const bool newSystrayIntegration = Preferences::systrayIntegration(); const bool newSystrayIntegration = Preferences::systrayIntegration();
actionLock_qBittorrent->setEnabled(newSystrayIntegration);
if(newSystrayIntegration != (systrayIcon!=0)) { if(newSystrayIntegration != (systrayIcon!=0)) {
if(newSystrayIntegration) { if(newSystrayIntegration) {
// create the trayicon // create the trayicon
@@ -935,8 +849,6 @@ void GUI::loadPreferences(bool configure_session) {
toolBar->setVisible(true); toolBar->setVisible(true);
toolBar->layout()->setSpacing(7); toolBar->layout()->setSpacing(7);
} else { } else {
// Clear search filter before hiding the top toolbar
search_filter->clear();
toolBar->setVisible(false); toolBar->setVisible(false);
} }
const uint new_refreshInterval = Preferences::getRefreshInterval(); const uint new_refreshInterval = Preferences::getRefreshInterval();
@@ -1119,8 +1031,6 @@ QMenu* GUI::getTrayIconMenu() {
myTrayIconMenu->addAction(actionPause_All); myTrayIconMenu->addAction(actionPause_All);
myTrayIconMenu->addSeparator(); myTrayIconMenu->addSeparator();
myTrayIconMenu->addAction(actionExit); myTrayIconMenu->addAction(actionExit);
if(ui_locked)
myTrayIconMenu->setEnabled(false);
return myTrayIconMenu; return myTrayIconMenu;
} }
@@ -1156,11 +1066,6 @@ void GUI::on_actionTop_tool_bar_triggered() {
Preferences::setToolbarDisplayed(is_visible); Preferences::setToolbarDisplayed(is_visible);
} }
void GUI::on_actionShutdown_when_downloads_complete_triggered() {
bool is_checked = static_cast<QAction*>(sender())->isChecked();
Preferences::setShutdownWhenDownloadsComplete(is_checked);
}
void GUI::on_actionSpeed_in_title_bar_triggered() { void GUI::on_actionSpeed_in_title_bar_triggered() {
displaySpeedInTitle = static_cast<QAction*>(sender())->isChecked(); displaySpeedInTitle = static_cast<QAction*>(sender())->isChecked();
Preferences::showSpeedInTitleBar(displaySpeedInTitle); Preferences::showSpeedInTitleBar(displaySpeedInTitle);

View File

@@ -57,8 +57,6 @@ class about;
class createtorrent; class createtorrent;
class downloadFromURL; class downloadFromURL;
class HidableTabWidget; class HidableTabWidget;
class LineEdit;
class QFileSystemWatcher;
class GUI : public QMainWindow, private Ui::MainWindow{ class GUI : public QMainWindow, private Ui::MainWindow{
Q_OBJECT Q_OBJECT
@@ -71,7 +69,6 @@ public:
QWidget* getCurrentTabWidget() const; QWidget* getCurrentTabWidget() const;
TransferListWidget* getTransferList() const { return transferList; } TransferListWidget* getTransferList() const { return transferList; }
QMenu* getTrayIconMenu(); QMenu* getTrayIconMenu();
PropertiesWidget *getProperties() const { return properties; }
public slots: public slots:
void trackerAuthenticationRequired(QTorrentHandle& h); void trackerAuthenticationRequired(QTorrentHandle& h);
@@ -100,10 +97,6 @@ protected slots:
void handleDownloadFromUrlFailure(QString, QString) const; void handleDownloadFromUrlFailure(QString, QString) const;
void createSystrayDelayed(); void createSystrayDelayed();
void tab_changed(int); void tab_changed(int);
void on_actionLock_qBittorrent_triggered();
void defineUILockPassword();
bool unlockUI();
void notifyOfUpdate(QString);
// Keyboard shortcuts // Keyboard shortcuts
void createKeyboardShortcuts(); void createKeyboardShortcuts();
void displayTransferTab() const; void displayTransferTab() const;
@@ -137,7 +130,6 @@ protected:
void displaySearchTab(bool enable); void displaySearchTab(bool enable);
private: private:
QFileSystemWatcher *executable_watcher;
// Bittorrent // Bittorrent
Bittorrent *BTSession; Bittorrent *BTSession;
QList<QPair<QTorrentHandle,QString> > unauthenticated_trackers; // Still needed? QList<QPair<QTorrentHandle,QString> > unauthenticated_trackers; // Still needed?
@@ -158,8 +150,6 @@ private:
PropertiesWidget *properties; PropertiesWidget *properties;
bool displaySpeedInTitle; bool displaySpeedInTitle;
bool force_exit; bool force_exit;
bool ui_locked;
LineEdit *search_filter;
// Keyboard shortcuts // Keyboard shortcuts
QShortcut *switchSearchShortcut; QShortcut *switchSearchShortcut;
QShortcut *switchSearchShortcut2; QShortcut *switchSearchShortcut2;
@@ -180,7 +170,6 @@ private slots:
void on_actionRSS_Reader_triggered(); void on_actionRSS_Reader_triggered();
void on_actionSpeed_in_title_bar_triggered(); void on_actionSpeed_in_title_bar_triggered();
void on_actionTop_tool_bar_triggered(); void on_actionTop_tool_bar_triggered();
void on_actionShutdown_when_downloads_complete_triggered();
}; };
#endif #endif

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 892 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 996 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 929 B

View File

@@ -1,6 +1,6 @@
[Desktop Entry] [Desktop Entry]
Categories=Qt;Network;P2P; Categories=Qt;Network;P2P;
Comment=V2.4.0 Comment=V2.3.1
Exec=qbittorrent %f Exec=qbittorrent %f
GenericName=Bittorrent client GenericName=Bittorrent client
GenericName[ar]=العميل Bittorrent GenericName[ar]=العميل Bittorrent

Binary file not shown.

Before

Width:  |  Height:  |  Size: 54 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 79 KiB

After

Width:  |  Height:  |  Size: 79 KiB

View File

@@ -47,7 +47,7 @@
<key>CFBundlePackageType</key> <key>CFBundlePackageType</key>
<string>APPL</string> <string>APPL</string>
<key>CFBundleGetInfoString</key> <key>CFBundleGetInfoString</key>
<string>2.4.0</string> <string>2.3.1</string>
<key>CFBundleSignature</key> <key>CFBundleSignature</key>
<string>????</string> <string>????</string>
<key>CFBundleExecutable</key> <key>CFBundleExecutable</key>

File diff suppressed because it is too large Load Diff

View File

@@ -108,7 +108,6 @@ public:
session* getSession() const; session* getSession() const;
QHash<QString, TrackerInfos> getTrackersInfo(QString hash) const; QHash<QString, TrackerInfos> getTrackersInfo(QString hash) const;
bool hasActiveTorrents() const; bool hasActiveTorrents() const;
bool hasDownloadingTorrents() const;
bool isQueueingEnabled() const; bool isQueueingEnabled() const;
int getMaximumActiveDownloads() const; int getMaximumActiveDownloads() const;
int getMaximumActiveTorrents() const; int getMaximumActiveTorrents() const;
@@ -200,9 +199,6 @@ protected slots:
void takeETASamples(); void takeETASamples();
void exportTorrentFiles(QString path); void exportTorrentFiles(QString path);
void saveTempFastResumeData(); void saveTempFastResumeData();
void sendNotificationEmail(QTorrentHandle h);
void autoRunExternalProgram(QTorrentHandle h, bool async=true);
void cleanUpAutoRunProcess(int);
signals: signals:
void addedTorrent(QTorrentHandle& h); void addedTorrent(QTorrentHandle& h);

View File

@@ -163,16 +163,6 @@ void EventManager::setGlobalPreferences(QVariantMap m) const {
} }
if(m.contains("export_dir")) if(m.contains("export_dir"))
Preferences::setExportDir(m["export_dir"].toString()); Preferences::setExportDir(m["export_dir"].toString());
if(m.contains("mail_notification_enabled"))
Preferences::setMailNotificationEnabled(m["mail_notification_enabled"].toBool());
if(m.contains("mail_notification_email"))
Preferences::setMailNotificationEmail(m["mail_notification_email"].toString());
if(m.contains("mail_notification_smtp"))
Preferences::setMailNotificationSMTP(m["mail_notification_smtp"].toString());
if(m.contains("autorun_enabled"))
Preferences::setAutoRunEnabled(m["autorun_enabled"].toBool());
if(m.contains("autorun_program"))
Preferences::setAutoRunProgram(m["autorun_program"].toString());
if(m.contains("preallocate_all")) if(m.contains("preallocate_all"))
Preferences::preAllocateAllFiles(m["preallocate_all"].toBool()); Preferences::preAllocateAllFiles(m["preallocate_all"].toBool());
if(m.contains("queueing_enabled")) if(m.contains("queueing_enabled"))
@@ -275,11 +265,6 @@ QVariantMap EventManager::getGlobalPreferences() const {
data["download_in_scan_dirs"] = var_list; data["download_in_scan_dirs"] = var_list;
data["export_dir_enabled"] = Preferences::isTorrentExportEnabled(); data["export_dir_enabled"] = Preferences::isTorrentExportEnabled();
data["export_dir"] = Preferences::getExportDir(); data["export_dir"] = Preferences::getExportDir();
data["mail_notification_enabled"] = Preferences::isMailNotificationEnabled();
data["mail_notification_email"] = Preferences::getMailNotificationEmail();
data["mail_notification_smtp"] = Preferences::getMailNotificationSMTP();
data["autorun_enabled"] = Preferences::isAutoRunEnabled();
data["autorun_program"] = Preferences::getAutoRunProgram();
data["preallocate_all"] = Preferences::preAllocateAllFiles(); data["preallocate_all"] = Preferences::preAllocateAllFiles();
data["queueing_enabled"] = Preferences::isQueueingSystemEnabled(); data["queueing_enabled"] = Preferences::isQueueingSystemEnabled();
data["max_active_downloads"] = Preferences::getMaxActiveDownloads(); data["max_active_downloads"] = Preferences::getMaxActiveDownloads();

View File

@@ -202,13 +202,12 @@ signals:
private: private:
void addTorrentsFromDir(const QDir &dir, QStringList &torrents) { void addTorrentsFromDir(const QDir &dir, QStringList &torrents) {
const QStringList files = dir.entryList(filters, QDir::Files, QDir::Unsorted); const QStringList files = dir.entryList(filters, QDir::Files, QDir::Unsorted);
foreach(const QString &file, files) { foreach(const QString &file, files)
#if defined(Q_WS_WIN) || defined(Q_OS_OS2) #if defined(Q_WS_WIN) || defined(Q_OS_OS2)
torrents << dir.absoluteFilePath(file).replace("/", "\\"); torrents << dir.absoluteFilePath(file).replace("/", "\\");
#else #else
torrents << dir.absoluteFilePath(file); torrents << dir.absoluteFilePath(file);
#endif #endif
}
} }
}; };

View File

@@ -109,7 +109,7 @@ QString HttpConnection::translateDocument(QString data) {
bool found = false; bool found = false;
do { do {
found = false; found = false;
QRegExp regex(QString::fromUtf8("_\\(([\\w\\s?!:\\/\\(\\),%µ&\\-\\.]+)\\)")); QRegExp regex(QString::fromUtf8("_\\(([\\w\\s?!:\\/\\(\\),µ&\\-\\.]+)\\)"));
i = regex.indexIn(data, i); i = regex.indexIn(data, i);
if(i >= 0) { if(i >= 0) {
//qDebug("Found translatable string: %s", regex.cap(1).toUtf8().data()); //qDebug("Found translatable string: %s", regex.cap(1).toUtf8().data());
@@ -161,7 +161,7 @@ void HttpConnection::respond() {
write(); write();
return; return;
} }
// Client successfully authenticated, reset number of failed attempts // Client sucessfuly authenticated, reset number of failed attempts
parent->resetNbFailedAttemptsForIp(peer_ip); parent->resetNbFailedAttemptsForIp(peer_ip);
QString url = parser.url(); QString url = parser.url();
// Favicon // Favicon
@@ -500,16 +500,6 @@ void HttpConnection::respondCommand(QString command)
if(h.is_valid()) h.queue_position_down(); if(h.is_valid()) h.queue_position_down();
return; return;
} }
if(command == "topPrio") {
QTorrentHandle h = BTSession->getTorrentHandle(parser.post("hash"));
if(h.is_valid()) h.queue_position_top();
return;
}
if(command == "bottomPrio") {
QTorrentHandle h = BTSession->getTorrentHandle(parser.post("hash"));
if(h.is_valid()) h.queue_position_bottom();
return;
}
if(command == "recheck"){ if(command == "recheck"){
recheckTorrent(parser.post("hash")); recheckTorrent(parser.post("hash"));
return; return;

View File

@@ -49,7 +49,6 @@
<file>Icons/skin/queued.png</file> <file>Icons/skin/queued.png</file>
<file>Icons/skin/checking.png</file> <file>Icons/skin/checking.png</file>
<file>Icons/skin/handle-icon.gif</file> <file>Icons/skin/handle-icon.gif</file>
<file>Icons/skin/arrow-right.gif</file>
<file>Icons/skin/filterinactive.png</file> <file>Icons/skin/filterinactive.png</file>
<file>Icons/skin/decrease.png</file> <file>Icons/skin/decrease.png</file>
<file>Icons/skin/play22.png</file> <file>Icons/skin/play22.png</file>
@@ -133,10 +132,8 @@
<file>Icons/oxygen/edit-copy.png</file> <file>Icons/oxygen/edit-copy.png</file>
<file>Icons/oxygen/folder-documents.png</file> <file>Icons/oxygen/folder-documents.png</file>
<file>Icons/oxygen/urlseed.png</file> <file>Icons/oxygen/urlseed.png</file>
<file>Icons/oxygen/go-up.png</file>
<file>Icons/oxygen/edit-cut.png</file> <file>Icons/oxygen/edit-cut.png</file>
<file>Icons/oxygen/gear32.png</file> <file>Icons/oxygen/gear32.png</file>
<file>Icons/oxygen/go-bottom.png</file>
<file>Icons/oxygen/user-group-delete.png</file> <file>Icons/oxygen/user-group-delete.png</file>
<file>Icons/oxygen/unsubscribe.png</file> <file>Icons/oxygen/unsubscribe.png</file>
<file>Icons/oxygen/tab-close.png</file> <file>Icons/oxygen/tab-close.png</file>
@@ -153,14 +150,12 @@
<file>Icons/oxygen/cookies.png</file> <file>Icons/oxygen/cookies.png</file>
<file>Icons/oxygen/network-server.png</file> <file>Icons/oxygen/network-server.png</file>
<file>Icons/oxygen/unsubscribe16.png</file> <file>Icons/oxygen/unsubscribe16.png</file>
<file>Icons/oxygen/encrypted32.png</file>
<file>Icons/oxygen/list-add.png</file> <file>Icons/oxygen/list-add.png</file>
<file>Icons/oxygen/edit-paste.png</file> <file>Icons/oxygen/edit-paste.png</file>
<file>Icons/oxygen/folder-remote.png</file> <file>Icons/oxygen/folder-remote.png</file>
<file>Icons/oxygen/help-about.png</file> <file>Icons/oxygen/help-about.png</file>
<file>Icons/oxygen/encrypted.png</file> <file>Icons/oxygen/encrypted.png</file>
<file>Icons/oxygen/folder-remote16.png</file> <file>Icons/oxygen/folder-remote16.png</file>
<file>Icons/oxygen/go-top.png</file>
<file>Icons/oxygen/edit_clear.png</file> <file>Icons/oxygen/edit_clear.png</file>
<file>Icons/oxygen/bug.png</file> <file>Icons/oxygen/bug.png</file>
<file>Icons/oxygen/gear.png</file> <file>Icons/oxygen/gear.png</file>
@@ -171,7 +166,6 @@
<file>Icons/oxygen/button_cancel.png</file> <file>Icons/oxygen/button_cancel.png</file>
<file>Icons/oxygen/preferences-desktop.png</file> <file>Icons/oxygen/preferences-desktop.png</file>
<file>Icons/oxygen/bt_settings.png</file> <file>Icons/oxygen/bt_settings.png</file>
<file>Icons/oxygen/go-down.png</file>
<file>Icons/oxygen/subscribe16.png</file> <file>Icons/oxygen/subscribe16.png</file>
<file>Icons/oxygen/download.png</file> <file>Icons/oxygen/download.png</file>
<file>Icons/oxygen/log.png</file> <file>Icons/oxygen/log.png</file>

Binary file not shown.

File diff suppressed because one or more lines are too long

Binary file not shown.

File diff suppressed because one or more lines are too long

Binary file not shown.

File diff suppressed because one or more lines are too long

Binary file not shown.

File diff suppressed because one or more lines are too long

Binary file not shown.

File diff suppressed because it is too large Load Diff

Binary file not shown.

File diff suppressed because it is too large Load Diff

Binary file not shown.

Some files were not shown because too many files have changed in this diff Show More