Permalink
Browse files

Fix -setFlipped: deprecation warning.

This removes old, pre-10.6 drawing code (including call to -setFlipped:) as we
no longer support 10.6.
  • Loading branch information...
Perspx committed May 8, 2015
1 parent 8f7081f commit b902e04b9cf74012df6c20245936fa87c3ed96bb
Showing with 6 additions and 16 deletions.
  1. +6 −16 PXSourceList/PXSourceList.m
@@ -425,22 +425,12 @@ - (void)drawRow:(NSInteger)rowIndex clipRect:(NSRect)clipRect
actualIconSize.width,
actualIconSize.height);
}
//Use 10.6 NSImage drawing if we can
if([icon respondsToSelector:@selector(drawInRect:fromRect:operation:fraction:respectFlipped:hints:)]) {
[icon drawInRect:iconRect
fromRect:NSZeroRect
operation:NSCompositeSourceOver
fraction:1
respectFlipped:YES hints:nil];
}
else {
[icon setFlipped:[self isFlipped]];
[icon drawInRect:iconRect
fromRect:NSZeroRect
operation:NSCompositeSourceOver
fraction:1];
}
[icon drawInRect:iconRect
fromRect:NSZeroRect
operation:NSCompositeSourceOver
fraction:1
respectFlipped:YES hints:nil];
}
}
}

0 comments on commit b902e04

Please sign in to comment.