Changeset 789


Ignore:
Timestamp:
Aug 17, 2006, 3:12:40 AM (15 years ago)
Author:
livings124
Message:

Show swarm speed in inspector.

Location:
trunk/macosx
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/macosx/English.lproj/InfoWindow.nib/classes.nib

    r784 r789  
    4040                fSizeField = NSTextField;
    4141                fStateField = NSTextField;
     42                fSwarmSpeedField = NSTextField;
    4243                fTabView = NSTabView;
    4344                fTorrentLocationField = NSTextField;
  • trunk/macosx/InfoWindowController.h

    r785 r789  
    4545                        * fDownloadedValidField, * fDownloadedTotalField, * fUploadedTotalField,
    4646                        * fRatioField, * fSeedersField, * fLeechersField,
    47                         * fConnectedPeersField, * fDownloadingFromField, * fUploadingToField;
     47                        * fConnectedPeersField, * fDownloadingFromField, * fUploadingToField, * fSwarmSpeedField;
    4848
    4949    IBOutlet NSTableView * fPeerTable;
  • trunk/macosx/InfoWindowController.m

    r785 r789  
    4141//15 spacing at the bottom of each tab
    4242#define TAB_INFO_HEIGHT 182.0
    43 #define TAB_ACTIVITY_HEIGHT 214.0
     43#define TAB_ACTIVITY_HEIGHT 230.0
    4444#define TAB_PEERS_HEIGHT 255.0
    4545#define TAB_FILES_HEIGHT 255.0
     
    167167        [fDownloadingFromField setStringValue: @""];
    168168        [fUploadingToField setStringValue: @""];
     169        [fSwarmSpeedField setStringValue: @""];
    169170       
    170171        [fPeers removeAllObjects];
     
    267268       
    268269        [fRatioField setStringValue: [NSString stringForRatioWithDownload: downloadedTotal upload: uploadedTotal]];
     270       
     271        [fSwarmSpeedField setStringValue: [torrent isActive] ? [NSString stringForSpeed: [torrent swarmSpeed]] : @""];
    269272       
    270273        //set peers table
  • trunk/macosx/Torrent.h

    r761 r789  
    133133- (uint64_t)    downloadedTotal;
    134134- (uint64_t)    uploadedTotal;
     135- (float)       swarmSpeed;
    135136
    136137- (NSNumber *) orderValue;
  • trunk/macosx/Torrent.m

    r780 r789  
    613613}
    614614
     615- (float) swarmSpeed
     616{
     617    return fStat->swarmspeed;
     618}
     619
    615620- (NSNumber *) orderValue
    616621{
Note: See TracChangeset for help on using the changeset viewer.