mirror of
https://github.com/brl/mutter.git
synced 2024-11-21 23:50:41 -05:00
cogl/onscreen/egl: Move pending_resize_notify to Xlib platform
It's only used in the Xlib onscreen, so move it there. Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1514>
This commit is contained in:
parent
b24d5ce1dd
commit
760a07cc24
@ -169,8 +169,6 @@ typedef struct _CoglOnscreenEGL
|
||||
{
|
||||
EGLSurface egl_surface;
|
||||
|
||||
gboolean pending_resize_notify;
|
||||
|
||||
/* Platform specific data */
|
||||
void *platform;
|
||||
} CoglOnscreenEGL;
|
||||
|
@ -60,6 +60,8 @@ typedef struct _CoglDisplayXlib
|
||||
typedef struct _CoglOnscreenXlib
|
||||
{
|
||||
Window xwin;
|
||||
|
||||
gboolean pending_resize_notify;
|
||||
} CoglOnscreenXlib;
|
||||
|
||||
#ifdef EGL_KHR_image_pixmap
|
||||
@ -103,11 +105,12 @@ flush_pending_resize_notifications_cb (void *data,
|
||||
{
|
||||
CoglOnscreen *onscreen = COGL_ONSCREEN (framebuffer);
|
||||
CoglOnscreenEGL *egl_onscreen = cogl_onscreen_get_winsys (onscreen);
|
||||
CoglOnscreenXlib *xlib_onscreen = egl_onscreen->platform;
|
||||
|
||||
if (egl_onscreen->pending_resize_notify)
|
||||
if (xlib_onscreen->pending_resize_notify)
|
||||
{
|
||||
_cogl_onscreen_notify_resize (onscreen);
|
||||
egl_onscreen->pending_resize_notify = FALSE;
|
||||
xlib_onscreen->pending_resize_notify = FALSE;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -140,6 +143,7 @@ notify_resize (CoglContext *context,
|
||||
CoglOnscreen *onscreen = find_onscreen_for_xid (context, drawable);
|
||||
CoglFramebuffer *framebuffer = COGL_FRAMEBUFFER (onscreen);
|
||||
CoglOnscreenEGL *egl_onscreen;
|
||||
CoglOnscreenXlib *xlib_onscreen;
|
||||
|
||||
if (!onscreen)
|
||||
return;
|
||||
@ -160,7 +164,8 @@ notify_resize (CoglContext *context,
|
||||
NULL);
|
||||
}
|
||||
|
||||
egl_onscreen->pending_resize_notify = TRUE;
|
||||
xlib_onscreen = egl_onscreen->platform;
|
||||
xlib_onscreen->pending_resize_notify = TRUE;
|
||||
}
|
||||
|
||||
static CoglFilterReturn
|
||||
|
Loading…
Reference in New Issue
Block a user