Add a note about wayland semantics
This commit is contained in:
parent
00324c96fc
commit
f6f2f00c53
6
glfw/wl_window.c
vendored
6
glfw/wl_window.c
vendored
@ -588,6 +588,12 @@ static void xdgSurfaceHandleConfigure(void* data,
|
|||||||
struct xdg_surface* surface,
|
struct xdg_surface* surface,
|
||||||
uint32_t serial)
|
uint32_t serial)
|
||||||
{
|
{
|
||||||
|
// The poorly documented pattern Wayland requires ack the configure,
|
||||||
|
// set the window geometry attach a new buffer of the correct size to the surface
|
||||||
|
// and only then commit the surface. buffer is attached only by eglSwapBuffers,
|
||||||
|
// so we set a flag to not commit the surface till the next swapbuffers. Note that
|
||||||
|
// wl_egl_window_resize() does not actually resize the buffer until the next draw call
|
||||||
|
// or buffer state query.
|
||||||
_GLFWwindow* window = data;
|
_GLFWwindow* window = data;
|
||||||
xdg_surface_ack_configure(surface, serial);
|
xdg_surface_ack_configure(surface, serial);
|
||||||
if (window->wl.pending_state & PENDING_STATE_TOPLEVEL) {
|
if (window->wl.pending_state & PENDING_STATE_TOPLEVEL) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user