FEATURE: Display pieces that are being downloaded

This commit is contained in:
Christophe Dumez
2010-03-18 23:03:56 +00:00
parent 758595dc8c
commit 9c3789f83f
5 changed files with 48 additions and 14 deletions

View File

@@ -338,7 +338,9 @@ void PropertiesWidget::loadDynamicData() {
if(!h.is_seed()) {
showPiecesDownloaded(true);
// Downloaded pieces
downloaded_pieces->setProgress(h.pieces());
bitfield bf(h.get_torrent_info().num_pieces(), 0);
h.downloading_pieces(bf);
downloaded_pieces->setProgress(h.pieces(), bf);
// Pieces availability
if(h.has_metadata() && !h.is_paused() && !h.is_queued() && !h.is_checking()) {
showPiecesAvailability(true);