1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2024-12-23 08:13:27 +00:00

(trunk qt) fix minor bugs in the torrent details dialog's info tab.

This commit is contained in:
Jordan Lee 2011-11-05 15:45:38 +00:00
parent 49ba5f230b
commit f569bae99c

View file

@ -360,9 +360,10 @@ Details :: refresh( )
bool isMixed = false;
bool allPaused = true;
bool allFinished = true;
const tr_torrent_activity activity = torrents[0]->getActivity( );
const tr_torrent_activity baseline = torrents[0]->getActivity( );
foreach( const Torrent * t, torrents ) {
if( activity != t->getActivity( ) )
const tr_torrent_activity activity = t->getActivity( );
if( activity != baseline )
isMixed = true;
if( activity != TR_STATUS_STOPPED )
allPaused = allFinished = false;
@ -445,10 +446,11 @@ Details :: refresh( )
myAvailabilityLabel->setText( string );
// myDownloadedLabel
uint64_t d = 0, f = 0;
if( torrents.empty( ) )
string = none;
else {
uint64_t d = 0;
uint64_t f = 0;
foreach( const Torrent * t, torrents ) {
d += t->downloadedEver( );
f += t->failedEver( );