1
0
mirror of https://github.com/wine-mirror/wine synced 2024-06-29 06:14:34 +00:00

winemac: Remove unused macdrv_get_surface_display_image copy_data parameter.

This commit is contained in:
Rémi Bernon 2024-05-30 13:28:41 +02:00 committed by Alexandre Julliard
parent 9cf95e76ef
commit 446c8ff670
3 changed files with 4 additions and 12 deletions

View File

@ -532,7 +532,7 @@ - (void) updateLayer
imageRect.origin.y *= layer.contentsScale;
imageRect.size.width *= layer.contentsScale;
imageRect.size.height *= layer.contentsScale;
image = macdrv_get_surface_display_image(window.surface, &imageRect, FALSE, window.colorKeyed,
image = macdrv_get_surface_display_image(window.surface, &imageRect, window.colorKeyed,
window.colorKeyRed, window.colorKeyGreen, window.colorKeyBlue);
if (image)

View File

@ -553,7 +553,7 @@ extern void macdrv_order_cocoa_window(macdrv_window w, macdrv_window prev,
extern void macdrv_get_cocoa_window_frame(macdrv_window w, CGRect* out_frame);
extern void macdrv_set_cocoa_parent_window(macdrv_window w, macdrv_window parent);
extern void macdrv_set_window_surface(macdrv_window w, struct window_surface *window_surface);
extern CGImageRef macdrv_get_surface_display_image(struct window_surface *window_surface, CGRect *rect, int copy_data, int color_keyed,
extern CGImageRef macdrv_get_surface_display_image(struct window_surface *window_surface, CGRect *rect, int color_keyed,
CGFloat key_red, CGFloat key_green, CGFloat key_blue);
extern void macdrv_window_needs_display(macdrv_window w, CGRect rect);
extern void macdrv_set_window_shape(macdrv_window w, const CGRect *rects, int count);

View File

@ -191,7 +191,7 @@ void set_surface_use_alpha(struct window_surface *window_surface, BOOL use_alpha
* must not use Win32 or Wine functions, including debug
* logging.
*/
CGImageRef macdrv_get_surface_display_image(struct window_surface *window_surface, CGRect *rect, int copy_data, int color_keyed,
CGImageRef macdrv_get_surface_display_image(struct window_surface *window_surface, CGRect *rect, int color_keyed,
CGFloat key_red, CGFloat key_green, CGFloat key_blue)
{
CGImageRef cgimage = NULL;
@ -220,15 +220,7 @@ CGImageRef macdrv_get_surface_display_image(struct window_surface *window_surfac
offset = CGRectGetMinX(visrect) * 4 + CGRectGetMinY(visrect) * bytes_per_row;
size = min(CGRectGetHeight(visrect) * bytes_per_row,
surface->info.bmiHeader.biSizeImage - offset);
if (copy_data)
{
CFDataRef data = CFDataCreate(NULL, (UInt8 *)window_surface->color_bits + offset, size);
provider = CGDataProviderCreateWithCFData(data);
CFRelease(data);
}
else
provider = CGDataProviderCreateWithData(NULL, (UInt8 *)window_surface->color_bits + offset, size, NULL);
provider = CGDataProviderCreateWithData(NULL, (UInt8 *)window_surface->color_bits + offset, size, NULL);
alphaInfo = surface->use_alpha ? kCGImageAlphaPremultipliedFirst : kCGImageAlphaNoneSkipFirst;
cgimage = CGImageCreate(CGRectGetWidth(visrect), CGRectGetHeight(visrect),