Changeset 1252


Ignore:
Timestamp:
Dec 18, 2006, 5:04:35 AM (15 years ago)
Author:
livings124
Message:

store upload rate / download rate in peer struct

Location:
trunk/libtransmission
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/transmission.c

    r1248 r1252  
    587587            peers[i].isConnected   = tr_peerIsConnected( peer );
    588588            peers[i].isIncoming    = tr_peerIsIncoming( peer );
    589             peers[i].isDownloading = tr_peerIsDownloading( peer );
    590             peers[i].isUploading   = tr_peerIsUploading( peer );
    591589            peers[i].progress      = tr_peerProgress( peer );
    592590            peers[i].port          = tr_peerPort( peer );
     591           
     592            if( ( peers[i].isDownloading = tr_peerIsDownloading( peer ) ) )
     593            {
     594                peers[i].downloadRate  = tr_peerDownloadRate( peer );
     595            }
     596            if( ( peers[i].isUploading = tr_peerIsUploading( peer ) ) )
     597            {
     598                peers[i].uploadRate  = tr_peerUploadRate( peer );
     599            }
    593600        }
    594601    }
  • trunk/libtransmission/transmission.h

    r1248 r1252  
    394394    int     isConnected;
    395395    int     isIncoming;
     396    float   progress;
     397    int     port;
     398   
    396399    int     isDownloading;
    397400    int     isUploading;
    398     float   progress;
    399     int     port;
     401    float   downloadRate;
     402    float   uploadRate;
    400403};
    401404
Note: See TracChangeset for help on using the changeset viewer.