From ff13d83f552563175881278ef344c05d67a93c43 Mon Sep 17 00:00:00 2001 From: Arnaud Fontaine Date: Fri, 28 Mar 2008 12:00:12 +0000 Subject: [PATCH] [mouse] Fix regression in moving --- mouse.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/mouse.c b/mouse.c index 7131162e..3babe9e8 100644 --- a/mouse.c +++ b/mouse.c @@ -150,15 +150,17 @@ uicb_client_movemouse(int screen, char *arg __attribute__ ((unused))) xcb_screen_t *s = xcb_aux_get_screen(globalconf.connection, c->phys_screen); if(!c - || xcb_grab_pointer_reply(globalconf.connection, - xcb_grab_pointer(globalconf.connection, false, - s->root, - MOUSEMASK, XCB_GRAB_MODE_ASYNC, XCB_GRAB_MODE_ASYNC, - s->root, - globalconf.cursor[CurMove], XCB_CURRENT_TIME), - NULL)) + || !(grab_pointer_r = xcb_grab_pointer_reply(globalconf.connection, + xcb_grab_pointer(globalconf.connection, false, + s->root, + MOUSEMASK, XCB_GRAB_MODE_ASYNC, XCB_GRAB_MODE_ASYNC, + s->root, + globalconf.cursor[CurMove], XCB_CURRENT_TIME), + NULL))) return; + p_delete(&grab_pointer_r); + query_pointer_r = xcb_query_pointer_reply(globalconf.connection, xcb_query_pointer_unchecked(globalconf.connection, s->root), @@ -187,8 +189,6 @@ uicb_client_movemouse(int screen, char *arg __attribute__ ((unused))) mouse_resizebar_draw(ctx, style, sw, geometry, c->border); } - p_delete(&grab_pointer_r); - for(;;) { /* TODO: need a review