winex11: Ignore color key and exposures when using the null surface.
This commit is contained in:
parent
a3b85a5a2e
commit
bdfab8cd88
|
@ -2059,6 +2059,8 @@ void set_surface_color_key( struct window_surface *window_surface, COLORREF colo
|
||||||
struct x11drv_window_surface *surface = get_x11_surface( window_surface );
|
struct x11drv_window_surface *surface = get_x11_surface( window_surface );
|
||||||
COLORREF prev;
|
COLORREF prev;
|
||||||
|
|
||||||
|
if (window_surface->funcs != &x11drv_surface_funcs) return; /* we may get the null surface */
|
||||||
|
|
||||||
window_surface->funcs->lock( window_surface );
|
window_surface->funcs->lock( window_surface );
|
||||||
prev = surface->color_key;
|
prev = surface->color_key;
|
||||||
set_color_key( surface, color_key );
|
set_color_key( surface, color_key );
|
||||||
|
@ -2074,6 +2076,8 @@ HRGN expose_surface( struct window_surface *window_surface, const RECT *rect )
|
||||||
struct x11drv_window_surface *surface = get_x11_surface( window_surface );
|
struct x11drv_window_surface *surface = get_x11_surface( window_surface );
|
||||||
HRGN region = 0;
|
HRGN region = 0;
|
||||||
|
|
||||||
|
if (window_surface->funcs != &x11drv_surface_funcs) return 0; /* we may get the null surface */
|
||||||
|
|
||||||
window_surface->funcs->lock( window_surface );
|
window_surface->funcs->lock( window_surface );
|
||||||
add_bounds_rect( &surface->bounds, rect );
|
add_bounds_rect( &surface->bounds, rect );
|
||||||
if (surface->region)
|
if (surface->region)
|
||||||
|
|
Loading…
Reference in New Issue