mirror of
https://github.com/d47081/qBittorrent.git
synced 2025-01-23 04:54:18 +00:00
Web UI: Remove unused code
This commit is contained in:
parent
8f439589ea
commit
ab0355f8d6
@ -105,11 +105,11 @@ void HttpConnection::translateDocument(QString& data) {
|
|||||||
static QRegExp regex(QString::fromUtf8("_\\(([\\w\\s?!:\\/\\(\\),%µ&\\-\\.]+)\\)"));
|
static QRegExp regex(QString::fromUtf8("_\\(([\\w\\s?!:\\/\\(\\),%µ&\\-\\.]+)\\)"));
|
||||||
static QRegExp mnemonic("\\(?&([a-zA-Z]?\\))?");
|
static QRegExp mnemonic("\\(?&([a-zA-Z]?\\))?");
|
||||||
const std::string contexts[] = {"TransferListFiltersWidget", "TransferListWidget",
|
const std::string contexts[] = {"TransferListFiltersWidget", "TransferListWidget",
|
||||||
"PropertiesWidget", "MainWindow", "HttpServer",
|
"PropertiesWidget", "MainWindow", "HttpServer",
|
||||||
"confirmDeletionDlg", "TrackerList", "TorrentFilesModel",
|
"confirmDeletionDlg", "TrackerList", "TorrentFilesModel",
|
||||||
"options_imp", "Preferences", "TrackersAdditionDlg",
|
"options_imp", "Preferences", "TrackersAdditionDlg",
|
||||||
"ScanFoldersModel", "PropTabBar", "TorrentModel",
|
"ScanFoldersModel", "PropTabBar", "TorrentModel",
|
||||||
"downloadFromURL"};
|
"downloadFromURL"};
|
||||||
int i = 0;
|
int i = 0;
|
||||||
bool found;
|
bool found;
|
||||||
|
|
||||||
@ -570,27 +570,10 @@ void HttpConnection::respondCommand(const QString& command) {
|
|||||||
recheckTorrent(m_parser.post("hash"));
|
recheckTorrent(m_parser.post("hash"));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if(command == "recheckall"){
|
|
||||||
recheckAllTorrents();
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void HttpConnection::recheckTorrent(const QString& hash) {
|
void HttpConnection::recheckTorrent(const QString& hash) {
|
||||||
QTorrentHandle h = QBtSession::instance()->getTorrentHandle(hash);
|
QBtSession::instance()->recheckTorrent(hash);
|
||||||
if(h.is_valid()){
|
|
||||||
QBtSession::instance()->recheckTorrent(h.hash());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
void HttpConnection::recheckAllTorrents() {
|
|
||||||
std::vector<torrent_handle> torrents = QBtSession::instance()->getTorrents();
|
|
||||||
std::vector<torrent_handle>::iterator torrentIT;
|
|
||||||
for(torrentIT = torrents.begin(); torrentIT != torrents.end(); torrentIT++) {
|
|
||||||
QTorrentHandle h = QTorrentHandle(*torrentIT);
|
|
||||||
if(h.is_valid())
|
|
||||||
QBtSession::instance()->recheckTorrent(h.hash());
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void HttpConnection::decreaseTorrentsPriority(const QStringList &hashes)
|
void HttpConnection::decreaseTorrentsPriority(const QStringList &hashes)
|
||||||
|
@ -66,7 +66,6 @@ protected slots:
|
|||||||
void processDownloadedFile(const QString& url, const QString& file_path);
|
void processDownloadedFile(const QString& url, const QString& file_path);
|
||||||
void handleDownloadFailure(const QString& url, const QString& reason);
|
void handleDownloadFailure(const QString& url, const QString& reason);
|
||||||
void recheckTorrent(const QString& hash);
|
void recheckTorrent(const QString& hash);
|
||||||
void recheckAllTorrents();
|
|
||||||
void decreaseTorrentsPriority(const QStringList& hashes);
|
void decreaseTorrentsPriority(const QStringList& hashes);
|
||||||
void increaseTorrentsPriority(const QStringList& hashes);
|
void increaseTorrentsPriority(const QStringList& hashes);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user