wined3d: Make sure we are still using the correct window before setting pixel format.
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
977f8cc64d
commit
548382e634
|
@ -1102,6 +1102,9 @@ static BOOL context_set_pixel_format(struct wined3d_context *context, HDC dc, BO
|
|||
if (dc == context->hdc && context->hdc_is_private && context->hdc_has_format)
|
||||
return TRUE;
|
||||
|
||||
if (dc == context->hdc && !context->hdc_is_private && WindowFromDC(dc) != context->win_handle)
|
||||
return FALSE;
|
||||
|
||||
current = gl_info->gl_ops.wgl.p_wglGetPixelFormat(dc);
|
||||
if (current == format) goto success;
|
||||
|
||||
|
|
Loading…
Reference in New Issue