mirror of
https://github.com/reactos/wine.git
synced 2024-11-25 04:39:45 +00:00
When possible, use the X window of the requested window in GetDC
instead of the parent to avoid trouble with OpenGL clipping.
This commit is contained in:
parent
d149d3cff3
commit
041c489a47
@ -416,16 +416,21 @@ BOOL X11DRV_GetDC( HWND hwnd, HDC hdc, HRGN hrgn, DWORD flags )
|
|||||||
|
|
||||||
if (top != hwnd)
|
if (top != hwnd)
|
||||||
{
|
{
|
||||||
escape.org.x = escape.org.y = 0;
|
escape.drawable_org.x = escape.drawable_org.y = 0;
|
||||||
if (flags & DCX_WINDOW)
|
if (flags & DCX_WINDOW)
|
||||||
{
|
{
|
||||||
escape.org.x = win->rectWindow.left - win->rectClient.left;
|
escape.org.x = win->rectWindow.left - win->rectClient.left;
|
||||||
escape.org.y = win->rectWindow.top - win->rectClient.top;
|
escape.org.y = win->rectWindow.top - win->rectClient.top;
|
||||||
|
MapWindowPoints( hwnd, top, &escape.org, 1 );
|
||||||
|
MapWindowPoints( top, 0, &escape.drawable_org, 1 );
|
||||||
|
escape.drawable = X11DRV_get_client_window( top );
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
escape.org.x = escape.org.y = 0;
|
||||||
|
MapWindowPoints( hwnd, 0, &escape.drawable_org, 1 );
|
||||||
|
escape.drawable = X11DRV_get_client_window( hwnd );
|
||||||
}
|
}
|
||||||
MapWindowPoints( hwnd, top, &escape.org, 1 );
|
|
||||||
escape.drawable_org.x = escape.drawable_org.y = 0;
|
|
||||||
MapWindowPoints( top, 0, &escape.drawable_org, 1 );
|
|
||||||
escape.drawable = X11DRV_get_client_window( top );
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user