- Torrents can now be rechecked from Web UI (patch by Stephanos Antaris)

- Torrents paused/resumed state is not reflected in GUI if the action was executed from Web UI
This commit is contained in:
Christophe Dumez 2009-11-17 08:15:26 +00:00
parent e30268cf3b
commit 4e8eaafd53
13 changed files with 77 additions and 49 deletions

View file

@ -164,19 +164,6 @@ bool bittorrent::isQueueingEnabled() const {
return queueingEnabled;
}
void bittorrent::increaseDlTorrentPriority(QString hash) {
Q_ASSERT(queueingEnabled);
QTorrentHandle h = getTorrentHandle(hash);
if(h.queue_position() > 0)
h.queue_position_up();
}
void bittorrent::decreaseDlTorrentPriority(QString hash) {
Q_ASSERT(queueingEnabled);
QTorrentHandle h = getTorrentHandle(hash);
h.queue_position_down();
}
void bittorrent::setUploadLimit(QString hash, long val) {
qDebug("Set upload limit rate to %ld", val);
QTorrentHandle h = getTorrentHandle(hash);
@ -207,18 +194,6 @@ void bittorrent::setQueueingEnabled(bool enable) {
}
}
int bittorrent::getDlTorrentPriority(QString hash) const {
Q_ASSERT(queueingEnabled);
QTorrentHandle h = getTorrentHandle(hash);
return h.queue_position();
}
int bittorrent::getUpTorrentPriority(QString hash) const {
Q_ASSERT(queueingEnabled);
QTorrentHandle h = getTorrentHandle(hash);
return h.queue_position();
}
// Set BT session configuration
void bittorrent::configureSession() {
qDebug("Configuring session");
@ -1575,8 +1550,11 @@ void bittorrent::readAlerts() {
if(h.is_valid()) {
h.auto_managed(false);
std::cerr << "File Error: " << p->message().c_str() << std::endl;
if(h.is_valid())
if(h.is_valid()) {
emit fullDiskError(h, misc::toQString(p->message()));
h.pause();
emit torrentPaused(h);
}
}
}
else if (dynamic_cast<listen_failed_alert*>(a.get())) {