diff --git a/src/fl_draw_image_mac.cxx b/src/fl_draw_image_mac.cxx index 72c34f888..86a86158a 100644 --- a/src/fl_draw_image_mac.cxx +++ b/src/fl_draw_image_mac.cxx @@ -84,15 +84,9 @@ static void innards(const uchar *buf, int X, int Y, int W, int H, lut = CGColorSpaceCreateDeviceRGB(); // a release callback is necessary when the fl_gc is a print context because the image data // must be kept until the page is closed. Thus tmpBuf can't be deleted here. It's too early. -#if MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_5 - typedef void (*CGDataProviderReleaseDataCallback) ( - void *info, - const void *data, - size_t size - ); -#endif - CGDataProviderReleaseDataCallback releaseCB = ( tmpBuf ? dataReleaseCB : NULL); - CGDataProviderRef src = CGDataProviderCreateWithData( 0L, array, linedelta*H, releaseCB); + CGDataProviderRef src = CGDataProviderCreateWithData( 0L, array, linedelta*H, + tmpBuf ? dataReleaseCB : NULL + ); CGImageRef img = CGImageCreate( W, H, 8, 8*delta, linedelta, //lut, delta&1?kCGImageAlphaNone:kCGImageAlphaNoneSkipLast, lut, delta&1?kCGImageAlphaNone:kCGImageAlphaLast,