de-flip priority images in the inspector

This commit is contained in:
Mitchell Livingston 2009-08-29 23:10:53 +00:00
parent a65f6243eb
commit 7cda4c5b1c
1 changed files with 10 additions and 1 deletions

View File

@ -25,6 +25,7 @@
#import "FilePriorityCell.h" #import "FilePriorityCell.h"
#import "FileOutlineView.h" #import "FileOutlineView.h"
#import "FileListNode.h" #import "FileListNode.h"
#import "NSApplicationAdditions.h"
#import "Torrent.h" #import "Torrent.h"
@implementation FilePriorityCell @implementation FilePriorityCell
@ -140,8 +141,16 @@
NSRect imageRect = NSMakeRect(cellFrame.origin.x + (cellFrame.size.width - imageSize.width) * 0.5, NSRect imageRect = NSMakeRect(cellFrame.origin.x + (cellFrame.size.width - imageSize.width) * 0.5,
cellFrame.origin.y + (cellFrame.size.height - imageSize.height) * 0.5, cellFrame.origin.y + (cellFrame.size.height - imageSize.height) * 0.5,
imageSize.width, imageSize.height); imageSize.width, imageSize.height);
if ([NSApp isOnSnowLeopardOrBetter])
[image drawInRect: imageRect fromRect: NSZeroRect operation: NSCompositeSourceOver fraction: 1.0
respectFlipped: YES hints: nil];
else
{
[image setFlipped: YES];
[image drawInRect: imageRect fromRect: NSZeroRect operation: NSCompositeSourceOver fraction: 1.0]; [image drawInRect: imageRect fromRect: NSZeroRect operation: NSCompositeSourceOver fraction: 1.0];
} }
} }
}
@end @end