Source

MYUtilities / ImageAndTextCell.m

Diff from to

File ImageAndTextCell.m

         imageFrame.origin.x += 3;
         imageFrame.size = imageSize;
 
-        if ([controlView isFlipped])
-            imageFrame.origin.y += ceilf((cellFrame.size.height + imageFrame.size.height) / 2);
-        else
-            imageFrame.origin.y += ceilf((cellFrame.size.height - imageFrame.size.height) / 2);
+        // I modified the following to avoid using 10.6-deprecated APIs. --Jens
+        
+        imageFrame.origin.y -= ceilf((cellFrame.size.height - imageFrame.size.height) / 2);
 
-        [image compositeToPoint:imageFrame.origin operation:NSCompositeSourceOver];
+        [image drawInRect: imageFrame
+                 fromRect: NSZeroRect
+                operation: NSCompositeSourceOver
+                 fraction: 1.0f
+           respectFlipped: YES
+                    hints: nil];
     }
     [super drawWithFrame:cellFrame inView:controlView];
 }