Changeset 2277


Ignore:
Timestamp:
Jul 3, 2007, 2:26:31 AM (15 years ago)
Author:
livings124
Message:

make progress bar yellow when checking cache (color is temporary until someone can make a real yellow one)

Location:
trunk/macosx
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/macosx/CTGradient/CTGradientAdditions.h

    r2149 r2277  
    3737+ (CTGradient *)progressGreenGradient;
    3838+ (CTGradient *)progressLightGreenGradient;
     39+ (CTGradient *)progressYellowGradient;
    3940+ (CTGradient *)progressTransparentGradient;
    4041@end
  • trunk/macosx/CTGradient/CTGradientAdditions.m

    r2149 r2277  
    311311}
    312312
     313+ (CTGradient *)progressYellowGradient
     314{
     315    #warning someone make a real one!
     316    return [CTGradient gradientWithBeginningColor: [NSColor orangeColor] endingColor: [NSColor yellowColor]];
     317}
     318
    313319+ (CTGradient *)progressTransparentGradient
    314320{
  • trunk/macosx/Torrent.m

    r2276 r2277  
    525525                                    [NSNumber numberWithFloat: (float)fStat->left/[self size]], @"Left",
    526526                                    [NSNumber numberWithBool: [self isActive]], @"Active",
     527                                    [NSNumber numberWithBool: [self isChecking]], @"Checking",
    527528                                    [NSNumber numberWithBool: [self isError]], @"Error", nil];
    528529   
     
    16591660        NSEnumerator * enumerator = [siblings objectEnumerator];
    16601661        while ((dict = [enumerator nextObject]))
    1661             if ([[dict objectForKey: @"Name"] isEqualToString: name] && [[dict objectForKey: @"IsFolder"] boolValue])
     1662            if ([[dict objectForKey: @"IsFolder"] boolValue] && [[dict objectForKey: @"Name"] isEqualToString: name])
    16621663                break;
    16631664    }
  • trunk/macosx/TorrentCell.h

    r2149 r2277  
    3333    NSImage * fErrorImage;
    3434    CTGradient * fWhiteGradient, * fGrayGradient, * fLightGrayGradient, * fLightGreenGradient,
    35                 * fGreenGradient, * fBlueGradient, * fTransparentGradient;
     35                * fGreenGradient, * fYellowGradient, * fBlueGradient, * fTransparentGradient;
    3636    NSUserDefaults * fDefaults;
    3737}
  • trunk/macosx/TorrentCell.m

    r2149 r2277  
    5353        fGreenGradient = [[CTGradient progressGreenGradient] retain];
    5454        fLightGreenGradient = [[CTGradient progressLightGreenGradient] retain];
     55        fYellowGradient = [[CTGradient progressYellowGradient] retain];
    5556        fTransparentGradient = [[CTGradient progressTransparentGradient] retain];
    5657       
     
    101102    }
    102103   
    103     if ([[info objectForKey: @"Seeding"] boolValue])
     104    if ([[info objectForKey: @"Checking"] boolValue])
     105        [fYellowGradient fillRect: completeBounds angle: -90];
     106    else if ([[info objectForKey: @"Seeding"] boolValue])
    104107    {
    105108        NSRect ratioBounds = completeBounds;
     
    110113        [fGreenGradient fillRect: ratioBounds angle: -90];
    111114    }
     115    else if ([[info objectForKey: @"Active"] boolValue])
     116        [fBlueGradient fillRect: completeBounds angle: -90];
    112117    else
    113     {
    114         if ([[info objectForKey: @"Active"] boolValue])
    115             [fBlueGradient fillRect: completeBounds angle: -90];
    116         else
    117             [fGrayGradient fillRect: completeBounds angle: -90];
    118     }
     118        [fGrayGradient fillRect: completeBounds angle: -90];
    119119   
    120120    [[NSColor colorWithDeviceWhite: 0.0 alpha: 0.2] set];
Note: See TracChangeset for help on using the changeset viewer.