From: Zebediah Figura zfigura@codeweavers.com
--- dlls/wineandroid.drv/opengl.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/dlls/wineandroid.drv/opengl.c b/dlls/wineandroid.drv/opengl.c index 41df3d3c09c..37e9c713fb1 100644 --- a/dlls/wineandroid.drv/opengl.c +++ b/dlls/wineandroid.drv/opengl.c @@ -497,8 +497,14 @@ static int android_wglGetPixelFormat( HDC hdc ) { struct gl_drawable *gl; int ret = 0; + HWND hwnd; + + if ((hwnd = NtUserWindowFromDC( hdc ))) + return win32u_get_window_pixel_format( hwnd );
- if ((gl = get_gl_drawable( NtUserWindowFromDC( hdc ), hdc ))) + /* This code is currently dead, but will be necessary if WGL_ARB_pbuffer + * support is introduced. */ + if ((gl = get_gl_drawable( NULL, hdc ))) { ret = gl->format; /* offscreen formats can't be used with traditional WGL calls */