mirror of https://github.com/snes9xgit/snes9x.git
Use XConfigureWindow instead of creating new ones. This doesn't exhibit
the expose problem that XResizeWindow shows.
This commit is contained in:
parent
a1e9887d58
commit
32edb0315e
|
@ -727,17 +727,15 @@ S9xOpenGLDisplayDriver::refresh (int width, int height)
|
|||
void
|
||||
S9xOpenGLDisplayDriver::resize_window (int width, int height)
|
||||
{
|
||||
g_object_unref (gdk_window);
|
||||
XDestroyWindow (display, xwindow);
|
||||
XWindowChanges changes;
|
||||
|
||||
changes.width = width;
|
||||
changes.height = height;
|
||||
XConfigureWindow (display, xwindow, CWWidth | CWHeight, &changes);
|
||||
XSync (display, False);
|
||||
|
||||
create_window (width, height);
|
||||
gdk_window_show (gdk_window);
|
||||
|
||||
glXMakeCurrent (display, xwindow, glx_context);
|
||||
|
||||
swap_control (config->sync_to_vblank);
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -39,11 +39,13 @@ S9xXVDisplayDriver::S9xXVDisplayDriver (Snes9xWindow *window,
|
|||
void
|
||||
S9xXVDisplayDriver::resize_window (int width, int height)
|
||||
{
|
||||
g_object_unref (gdk_window);
|
||||
XDestroyWindow (display, xwindow);
|
||||
XWindowChanges changes;
|
||||
|
||||
changes.width = width;
|
||||
changes.height = height;
|
||||
XConfigureWindow (display, xwindow, CWWidth | CWHeight, &changes);
|
||||
XSync (display, False);
|
||||
|
||||
create_window (width, height);
|
||||
gdk_window_show (gdk_window);
|
||||
|
||||
return;
|
||||
|
|
Loading…
Reference in New Issue