Changeset 7077


Ignore:
Timestamp:
Nov 8, 2008, 10:13:00 PM (12 years ago)
Author:
livings124
Message:

trivial changes to table grid color drawing and other areas

Location:
trunk/macosx
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/macosx/BadgeView.m

    r6959 r7077  
    5858{
    5959    //only needs update if the badges were displayed or are displayed now
    60     BOOL needsUpdate = fDownloadRate != downloadRate || fUploadRate != uploadRate;
    61     if (needsUpdate)
    62     {
    63         fDownloadRate = downloadRate;
    64         fUploadRate = uploadRate;
    65     }
     60    if (fDownloadRate == downloadRate && fUploadRate == uploadRate)
     61        return NO;
    6662   
    67     return needsUpdate;
     63    fDownloadRate = downloadRate;
     64    fUploadRate = uploadRate;
     65    return YES;
    6866}
    6967
  • trunk/macosx/Badger.m

    r7075 r7077  
    9797        return;
    9898    }
    99     else if (fQuittingTiger)
     99   
     100    if (fQuittingTiger)
    100101        return;
    101     else;
    102102   
    103103    //set completed badge to top right
  • trunk/macosx/Controller.m

    r7071 r7077  
    42304230        while ((torrent = [enumerator nextObject]))
    42314231            if (torrentStruct == [torrent torrentStruct])
     4232            {
     4233                [torrent retain];
    42324234                break;
     4235            }
    42334236       
    42344237        if (!torrent)
     
    42394242            return;
    42404243        }
    4241        
    4242         [torrent retain];
    42434244    }
    42444245   
  • trunk/macosx/TorrentTableView.m

    r7030 r7077  
    739739        visibleRect.origin.y = newY;
    740740    }
    741    
     741       
    742742    //remaining visible rows continue alternating
    743     CGFloat height = [self rowHeight] + [self intercellSpacing].height;
    744     NSInteger numberOfRects = ceil(visibleRect.size.height / height);
     743    const CGFloat height = [self rowHeight] + [self intercellSpacing].height;
     744    const NSInteger numberOfRects = ceil(visibleRect.size.height / height);
     745   
    745746    visibleRect.size.height = height;
    746    
    747     for (NSInteger i=0; i<numberOfRects; i++)
    748     {
    749         if (!start)
    750             NSRectFill(visibleRect);
    751        
    752         start = !start;
     747    if (start)
    753748        visibleRect.origin.y += height;
     749   
     750    for (NSInteger i = start ? 1 : 0; i<numberOfRects; i += 2)
     751    {
     752        NSRectFill(visibleRect);
     753        visibleRect.origin.y += 2 * height;
    754754    }
    755755   
  • trunk/macosx/TrackerTableView.m

    r7005 r7077  
    8787   
    8888    //remaining visible rows continue alternating
    89     CGFloat height = [self rowHeight] + [self intercellSpacing].height;
    90     NSInteger numberOfRects = ceil(visibleRect.size.height / height);
     89    const CGFloat height = [self rowHeight] + [self intercellSpacing].height;
     90    const NSInteger numberOfRects = ceil(visibleRect.size.height / height);
     91   
    9192    visibleRect.size.height = height;
     93    if (start)
     94        visibleRect.origin.y += height;
    9295   
    93     for (NSInteger i=0; i<numberOfRects; i++)
     96    for (NSInteger i = start ? 1 : 0; i<numberOfRects; i += 2)
    9497    {
    95         if (!start)
    96             NSRectFill(visibleRect);
    97        
    98         start = !start;
    99         visibleRect.origin.y += height;
     98        NSRectFill(visibleRect);
     99        visibleRect.origin.y += 2 * height;
    100100    }
    101101   
Note: See TracChangeset for help on using the changeset viewer.