From 57e0ce1d2afd1c5c335f43f38a348ddbcbefdcf1 Mon Sep 17 00:00:00 2001 From: Ander Conselvan de Oliveira Date: Tue, 26 Jun 2012 17:09:11 +0300 Subject: [PATCH] simple-egl: Make window moveable --- clients/simple-egl.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/clients/simple-egl.c b/clients/simple-egl.c index 25c7bdf..0091172 100644 --- a/clients/simple-egl.c +++ b/clients/simple-egl.c @@ -28,6 +28,8 @@ #include #include +#include + #include #include @@ -380,6 +382,11 @@ pointer_handle_button(void *data, struct wl_pointer *wl_pointer, uint32_t serial, uint32_t time, uint32_t button, uint32_t state) { + struct display *display = data; + + if (button == BTN_LEFT && state == WL_POINTER_BUTTON_STATE_PRESSED) + wl_shell_surface_move(display->window->shell_surface, + display->seat, serial); } static void -- 2.7.4