Changeset 5459


Ignore:
Timestamp:
Mar 31, 2008, 6:33:34 PM (14 years ago)
Author:
livings124
Message:

only show "selected" in the progress bar (and allow toggling) for multifile torrents

Location:
trunk/macosx
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/macosx/Torrent.m

    r5457 r5459  
    971971    if (![self allDownloaded])
    972972    {
    973         if ([fDefaults boolForKey: @"DisplayStatusProgressSelected"])
     973        if ([self folder] && [fDefaults boolForKey: @"DisplayStatusProgressSelected"])
    974974        {
    975975            string = [NSString localizedStringWithFormat: NSLocalizedString(@"%@ of %@ selected (%.2f%%)",
     
    984984    else if (![self isComplete])
    985985    {
    986         if ([fDefaults boolForKey: @"DisplayStatusProgressSelected"])
     986        if ([self folder] && [fDefaults boolForKey: @"DisplayStatusProgressSelected"])
    987987            string = [NSString stringWithFormat: NSLocalizedString(@"%@ selected, uploaded %@ (Ratio: %@)",
    988988                "Torrent -> progress string"), [NSString stringForFileSize: [self haveTotal]],
  • trunk/macosx/TorrentCell.m

    r5341 r5459  
    258258    if (NSMouseInRect(point, [self controlButtonRectForBounds: cellFrame], [controlView isFlipped])
    259259        || NSMouseInRect(point, [self revealButtonRectForBounds: cellFrame], [controlView isFlipped])
    260         || NSMouseInRect(point, [self progressRectForBounds: cellFrame], [controlView isFlipped])
     260        || (NSMouseInRect(point, [self progressRectForBounds: cellFrame], [controlView isFlipped]) && [[self representedObject] folder])
    261261        || NSMouseInRect(point, [self minimalStatusRectForBounds: cellFrame], [controlView isFlipped]))
    262262        return NSCellHitContentArea | NSCellHitTrackableArea;
     
    285285   
    286286    NSRect progressRect = [self progressRectForBounds: cellFrame];
    287     BOOL checkProgress = NSMouseInRect(point, progressRect, [controlView isFlipped]);
     287    BOOL checkProgress = NSMouseInRect(point, progressRect, [controlView isFlipped]) && [[self representedObject] folder];
    288288   
    289289    NSRect minimalStatusRect = [self minimalStatusRectForBounds: cellFrame];
  • trunk/macosx/TorrentTableView.m

    r5348 r5459  
    781781}
    782782
     783#warning finish folder check
    783784- (BOOL) pointInProgressRect: (NSPoint) point
    784785{
    785786    int row = [self rowAtPoint: point];
    786     if (row < 0 || ![[self itemAtRow: row] isKindOfClass: [Torrent class]] || [fDefaults boolForKey: @"SmallView"])
     787    if (row < 0 || ![[self itemAtRow: row] isKindOfClass: [Torrent class]] || [fDefaults boolForKey: @"SmallView"]
     788        || ![[self itemAtRow: row] folder])
    787789        return NO;
    788790   
Note: See TracChangeset for help on using the changeset viewer.