mirror of
https://github.com/rakshasa/rtorrent.git
synced 2026-10-07 14:49:21 +00:00
* Replaced the old TrackerList API with the cleaned up
TrackerContainer code. git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1005 e378c898-3ddf-0310-93e7-cc216c733640
This commit is contained in:
@@ -188,11 +188,11 @@ print_download_status(char* first, char* last, core::Download* d) {
|
||||
first = print_buffer(first, last, "Checking hash [%2i%%]",
|
||||
(d->download()->chunks_hashed() * 100) / d->download()->file_list()->size_chunks());
|
||||
|
||||
} else if (d->tracker_list()->is_busy() && d->tracker_list()->focus() < d->tracker_list()->size()) {
|
||||
} else if (d->tracker_list()->has_active() && d->tracker_list()->focus() < d->tracker_list()->end()) {
|
||||
torrent::TrackerList* tl = d->tracker_list();
|
||||
|
||||
first = print_buffer(first, last, "Tracker[%i:%i]: Connecting to %s",
|
||||
tl->get(tl->focus())->group(), tl->focus(), tl->get(tl->focus())->url().c_str());
|
||||
(*tl->focus())->group(), tl->focus_index(), (*tl->focus())->url().c_str());
|
||||
|
||||
} else if (!d->message().empty()) {
|
||||
first = print_buffer(first, last, "%s", d->message().c_str());
|
||||
|
||||
@@ -83,8 +83,8 @@ WindowDownloadStatusbar::redraw() {
|
||||
|
||||
position = print_download_status(buffer, last, m_download);
|
||||
m_canvas->print(0, 2, "[%c:%i] %s",
|
||||
m_download->tracker_list()->is_busy() ? 'C' : ' ',
|
||||
(int)(m_download->download()->tracker_list().timeout() / 1000000),
|
||||
m_download->tracker_list()->has_active() ? 'C' : ' ',
|
||||
(int)(m_download->download()->tracker_list()->time_next_connection()),
|
||||
buffer);
|
||||
}
|
||||
|
||||
|
||||
@@ -75,7 +75,7 @@ WindowTrackerList::redraw() {
|
||||
Range range = rak::advance_bidirectional<unsigned int>(0, *m_focus, tl->size(), (m_canvas->height() + 1) / 2);
|
||||
|
||||
while (range.first != range.second) {
|
||||
torrent::Tracker* tracker = tl->get(range.first);
|
||||
torrent::Tracker* tracker = tl->at(range.first);
|
||||
|
||||
// m_canvas->print(0, pos, "[%c] [S/L %5i/%5i] %s",
|
||||
// tracker->is_enabled() ? (tracker->is_open() ? '*' : ' ') : '-',
|
||||
@@ -90,7 +90,7 @@ WindowTrackerList::redraw() {
|
||||
|
||||
m_canvas->print(4, pos++, "Id: %s Focus: %s Enabled: %s Open: %s S/L: %u/%u",
|
||||
rak::copy_escape_html(tracker->tracker_id()).c_str(),
|
||||
range.first == tl->focus() ? "yes" : " no",
|
||||
range.first == tl->focus_index() ? "yes" : " no",
|
||||
tracker->is_enabled() ? "yes" : " no",
|
||||
tracker->is_busy() ? "yes" : " no",
|
||||
tracker->scrape_complete(),
|
||||
|
||||
Reference in New Issue
Block a user