diff options
Diffstat (limited to 'examples/input-inhibitor.c')
-rw-r--r-- | examples/input-inhibitor.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/examples/input-inhibitor.c b/examples/input-inhibitor.c index 80be3916..a0acebd0 100644 --- a/examples/input-inhibitor.c +++ b/examples/input-inhibitor.c @@ -18,12 +18,12 @@ static struct xdg_wm_base *wm_base = NULL; static struct zwlr_input_inhibit_manager_v1 *input_inhibit_manager = NULL; static struct zwlr_input_inhibitor_v1 *input_inhibitor = NULL; -struct wlr_egl egl; +struct wlr_egl *egl; struct wl_egl_window *egl_window; struct wlr_egl_surface *egl_surface; static void render_frame(void) { - eglMakeCurrent(egl.display, egl_surface, egl_surface, egl.context); + eglMakeCurrent(egl->display, egl_surface, egl_surface, egl->context); glViewport(0, 0, width, height); if (keys) { @@ -33,7 +33,7 @@ static void render_frame(void) { } glClear(GL_COLOR_BUFFER_BIT); - eglSwapBuffers(egl.display, egl_surface); + eglSwapBuffers(egl->display, egl_surface); } static void xdg_surface_handle_configure(void *data, @@ -158,7 +158,7 @@ int main(int argc, char **argv) { assert(input_inhibitor); EGLint attribs[] = { EGL_NONE }; - wlr_egl_init(&egl, EGL_PLATFORM_WAYLAND_EXT, display, attribs); + egl = wlr_egl_create(EGL_PLATFORM_WAYLAND_EXT, display, attribs); struct wl_surface *surface = wl_compositor_create_surface(compositor); assert(surface); @@ -174,7 +174,7 @@ int main(int argc, char **argv) { wl_surface_commit(surface); egl_window = wl_egl_window_create(surface, width, height); - egl_surface = wlr_egl_create_surface(&egl, egl_window); + egl_surface = wlr_egl_create_surface(egl, egl_window); wl_display_roundtrip(display); |