Commit af0cff55 authored by Marcus Meissner's avatar Marcus Meissner Committed by Alexandre Julliard

When flipping backbuffer -> frontbuffer, first exchange surfaces, then

copy XImage, since the palette might only be defined in the frontbuffer.
parent d178fb02
......@@ -840,8 +840,6 @@ static HRESULT WINAPI Xlib_IDirectDrawSurface4Impl_Flip(
if (!This->s.ddraw->d.paintable)
return DD_OK;
Xlib_copy_surface_on_screen(iflipto);
/* We need to switch the lowlevel surfaces, for xlib this is: */
/* The surface pointer */
surf = This->s.surface_desc.y.lpSurface;
......@@ -852,6 +850,8 @@ static HRESULT WINAPI Xlib_IDirectDrawSurface4Impl_Flip(
This->t.xlib.image = iflipto->t.xlib.image;
iflipto->t.xlib.image = image;
Xlib_copy_surface_on_screen(This);
if (iflipto->s.palette && iflipto->s.palette->cm)
TSXSetWindowColormap(display,This->s.ddraw->d.drawable,iflipto->s.palette->cm);
return DD_OK;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment