Changeset 6980


Ignore:
Timestamp:
Oct 29, 2008, 2:33:20 AM (12 years ago)
Author:
livings124
Message:

hardcode the max group constant; trivial changes

Location:
trunk/macosx
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/macosx/Controller.m

    r6958 r6980  
    23542354- (void) autoSpeedLimitChange: (NSNotification *) notification
    23552355{
    2356     //clear timer here in case its not being reset
     2356    //clear timer here in case it's not being reset
    23572357    [fSpeedLimitTimer invalidate];
    23582358    fSpeedLimitTimer = nil;
  • trunk/macosx/NSMenuAdditions.m

    r6889 r6980  
    2929- (void) appendItemsFromMenu: (NSMenu *) menu atIndexes: (NSIndexSet *) indexes atBottom: (BOOL) bottom
    3030{
    31     int bottomIndex = bottom ? [self numberOfItems] : 0;
     31    NSInteger bottomIndex = bottom ? [self numberOfItems] : 0;
    3232   
    3333    NSMenuItem * item;
  • trunk/macosx/PeerProgressIndicatorCell.m

    r5349 r6980  
    4646    {
    4747        if (!fAttributes)
    48             fAttributes = [[NSDictionary alloc] initWithObjectsAndKeys: [NSFont systemFontOfSize: 11.0], NSFontAttributeName, nil];
    49         [[NSString localizedStringWithFormat: @"%.1f%%", [self floatValue] * 100.0] drawInRect: cellFrame withAttributes: fAttributes];
     48            fAttributes = [[NSDictionary alloc] initWithObjectsAndKeys: [NSFont systemFontOfSize: 11.0f], NSFontAttributeName, nil];
     49        [[NSString localizedStringWithFormat: @"%.1f%%", [self floatValue] * 100.0f] drawInRect: cellFrame withAttributes: fAttributes];
    5050    }
    5151    else
     
    5959       
    6060        [super drawWithFrame: cellFrame inView: controlView];
    61         if ([self floatValue] >= 1.0)
     61        if ([self floatValue] >= 1.0f)
    6262        {
    6363            NSImage * checkImage = [NSImage imageNamed: @"CompleteCheck.png"];
     
    6565           
    6666            NSSize imageSize = [checkImage size];
    67             NSRect rect = NSMakeRect(cellFrame.origin.x + (cellFrame.size.width - imageSize.width) * 0.5,
    68                         cellFrame.origin.y + (cellFrame.size.height - imageSize.height) * 0.5, imageSize.width, imageSize.height);
    69             [checkImage drawInRect: rect fromRect: NSZeroRect operation: NSCompositeSourceOver fraction: 1.0];
     67            NSRect rect = NSMakeRect(cellFrame.origin.x + (cellFrame.size.width - imageSize.width) * 0.5f,
     68                        cellFrame.origin.y + (cellFrame.size.height - imageSize.height) * 0.5f, imageSize.width, imageSize.height);
     69            [checkImage drawInRect: rect fromRect: NSZeroRect operation: NSCompositeSourceOver fraction: 1.0f];
    7070        }
    7171    }
  • trunk/macosx/TorrentGroup.m

    r6974 r6980  
    7171- (CGFloat) uploadRate
    7272{
    73     float rate = 0.0f;
     73    CGFloat rate = 0.0f;
    7474    NSEnumerator * enumerator = [fTorrents objectEnumerator];
    7575    Torrent * torrent;
     
    8282- (CGFloat) downloadRate
    8383{
    84     float rate = 0.0f;
     84    CGFloat rate = 0.0f;
    8585    NSEnumerator * enumerator = [fTorrents objectEnumerator];
    8686    Torrent * torrent;
  • trunk/macosx/TorrentTableView.m

    r6979 r6980  
    3131#import "NSApplicationAdditions.h"
    3232
    33 #define MAX_GROUP (INT_MAX-10)
     33#define MAX_GROUP 999999
    3434
    3535#define ACTION_MENU_GLOBAL_TAG 101
Note: See TracChangeset for help on using the changeset viewer.