mirror of
git://source.winehq.org/git/wine.git
synced 2024-10-31 12:54:13 +00:00
user32: Don't paint to the surface if the window has a pixel format, regardless of the state of the top parent.
This commit is contained in:
parent
bc602c3060
commit
0cc78d97c1
1 changed files with 11 additions and 5 deletions
|
@ -113,6 +113,7 @@ static void update_visible_region( struct dce *dce )
|
|||
HRGN vis_rgn = 0;
|
||||
HWND top_win = 0;
|
||||
DWORD flags = dce->flags;
|
||||
DWORD paint_flags = 0;
|
||||
size_t size = 256;
|
||||
RECT win_rect, top_rect;
|
||||
WND *win;
|
||||
|
@ -149,6 +150,7 @@ static void update_visible_region( struct dce *dce )
|
|||
top_rect.top = reply->top_rect.top;
|
||||
top_rect.right = reply->top_rect.right;
|
||||
top_rect.bottom = reply->top_rect.bottom;
|
||||
paint_flags = reply->paint_flags;
|
||||
}
|
||||
else size = reply->total_size;
|
||||
}
|
||||
|
@ -163,12 +165,16 @@ static void update_visible_region( struct dce *dce )
|
|||
if (dce->clip_rgn) CombineRgn( vis_rgn, vis_rgn, dce->clip_rgn,
|
||||
(flags & DCX_INTERSECTRGN) ? RGN_AND : RGN_DIFF );
|
||||
|
||||
if ((win = WIN_GetPtr( top_win )) && win != WND_DESKTOP && win != WND_OTHER_PROCESS)
|
||||
/* don't use a surface to paint the client area of OpenGL windows */
|
||||
if (!(paint_flags & SET_WINPOS_PIXEL_FORMAT) || (flags & DCX_WINDOW))
|
||||
{
|
||||
/* don't use a surface to paint the client area of OpenGL windows */
|
||||
if (!win->pixel_format || (flags & DCX_WINDOW)) surface = win->surface;
|
||||
if (surface) window_surface_add_ref( surface );
|
||||
WIN_ReleasePtr( win );
|
||||
win = WIN_GetPtr( top_win );
|
||||
if (win && win != WND_DESKTOP && win != WND_OTHER_PROCESS)
|
||||
{
|
||||
surface = win->surface;
|
||||
if (surface) window_surface_add_ref( surface );
|
||||
WIN_ReleasePtr( win );
|
||||
}
|
||||
}
|
||||
|
||||
if (!surface) top_rect = get_virtual_screen_rect();
|
||||
|
|
Loading…
Reference in a new issue