diff --git a/macosx/ImageBackgroundView.h b/macosx/ImageBackgroundView.h index 0a9d9a00f..df214097c 100644 --- a/macosx/ImageBackgroundView.h +++ b/macosx/ImageBackgroundView.h @@ -1,4 +1,26 @@ -/* ImageBackgroundView */ +/****************************************************************************** + * $Id$ + * + * Copyright (c) 2006 Transmission authors and contributors + * + * Permission is hereby granted, free of charge, to any person obtaining a + * copy of this software and associated documentation files (the "Software"), + * to deal in the Software without restriction, including without limitation + * the rights to use, copy, modify, merge, publish, distribute, sublicense, + * and/or sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER + * DEALINGS IN THE SOFTWARE. + *****************************************************************************/ #import diff --git a/macosx/ImageBackgroundView.m b/macosx/ImageBackgroundView.m index 14abc24f5..ee804a349 100644 --- a/macosx/ImageBackgroundView.m +++ b/macosx/ImageBackgroundView.m @@ -1,3 +1,27 @@ +/****************************************************************************** + * $Id$ + * + * Copyright (c) 2006 Transmission authors and contributors + * + * Permission is hereby granted, free of charge, to any person obtaining a + * copy of this software and associated documentation files (the "Software"), + * to deal in the Software without restriction, including without limitation + * the rights to use, copy, modify, merge, publish, distribute, sublicense, + * and/or sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER + * DEALINGS IN THE SOFTWARE. + *****************************************************************************/ + #import "ImageBackgroundView.h" @implementation ImageBackgroundView @@ -6,6 +30,7 @@ { if (fBackgroundColor) [fBackgroundColor release]; + fBackgroundColor = [[NSColor colorWithPatternImage: image] retain]; } diff --git a/macosx/Torrent.m b/macosx/Torrent.m index 18a190b6e..88c039ea5 100644 --- a/macosx/Torrent.m +++ b/macosx/Torrent.m @@ -599,7 +599,9 @@ - (NSNumber *) progressSortKey { - return [NSNumber numberWithFloat: [self progress]]; + //if finished downloading sort by ratio instead of progress + float progress = [self progress]; + return [NSNumber numberWithFloat: progress < 1.0 ? progress : 2.0 + [self ratio]]; } @end diff --git a/macosx/TorrentCell.m b/macosx/TorrentCell.m index 23455c5c1..f2c3af6d0 100644 --- a/macosx/TorrentCell.m +++ b/macosx/TorrentCell.m @@ -285,7 +285,7 @@ static uint32_t kRed = BE(0xFF6450FF), //255, 100, 80 BOOL highlighted = [self isHighlighted] && [[self highlightColorWithFrame: cellFrame inView: view] isEqual: [NSColor alternateSelectedControlColor]]; NSDictionary * nameAttributes = [[NSDictionary alloc] initWithObjectsAndKeys: - highlighted ? [NSColor whiteColor] : [NSColor blackColor], NSForegroundColorAttributeName, + highlighted ? [NSColor whiteColor] : [NSColor controlTextColor], NSForegroundColorAttributeName, [NSFont messageFontOfSize: 12.0], NSFontAttributeName, nil]; NSDictionary * statusAttributes = [[NSDictionary alloc] initWithObjectsAndKeys: highlighted ? [NSColor whiteColor] : [NSColor darkGrayColor], NSForegroundColorAttributeName,