diff options
author | Kristian Høgsberg <krh@bitplanet.net> | 2013-05-16 15:31:07 -0400 |
---|---|---|
committer | Kristian Høgsberg <krh@bitplanet.net> | 2013-05-16 15:31:07 -0400 |
commit | ca0731461a2cf87e713fa11e54fe86b68b0c94b7 (patch) | |
tree | 279847f21305e832ca9021e8ad3eeb91f87bbc1a | |
parent | 057cbba2d3863a1503fbfbb6a49a42624a204e04 (diff) |
Print more events
-rw-r--r-- | NOTES | 2 | ||||
-rw-r--r-- | src/input.c | 2 | ||||
-rw-r--r-- | src/test.c | 26 |
3 files changed, 29 insertions, 1 deletions
@@ -12,3 +12,5 @@ but we'll also need full substructure redirect since apps can do that on their own windows. + + - Problem with popup placement and other global coords.
\ No newline at end of file diff --git a/src/input.c b/src/input.c index ec8a106..ea092a2 100644 --- a/src/input.c +++ b/src/input.c @@ -83,7 +83,7 @@ pointer_handle_leave(void *data, struct wl_pointer *pointer, seat->pointer_focus = wl_surface_get_user_data(surface); window = seat->pointer_focus; if (window->event_mask & EnterWindowMask) - csx_seat_send_cronssing_event(seat, EnterNotify); + csx_seat_send_cronssing_event(seat, LeaveNotify); } static void @@ -11,6 +11,30 @@ print_event(XEvent *e) printf("got MapNotify event: window %d\n", e->xmap.window); break; + case ReparentNotify: + printf("got ReparentNotify event: window %d\n", + e->xmap.window); + break; + case MotionNotify: + printf("got MotionNotify event: window %d\n", + e->xmap.window); + break; + case ButtonPress: + printf("got ButtonPress event: window %d\n", + e->xmap.window); + break; + case ButtonRelease: + printf("got ButtonRelease event: window %d\n", + e->xmap.window); + break; + case EnterNotify: + printf("got EnterNotify event: window %d\n", + e->xmap.window); + break; + case LeaveNotify: + printf("got LeaveaNotify event: window %d\n", + e->xmap.window); + break; default: printf("got event type %d\n", e->type); break; @@ -42,6 +66,8 @@ int main(int argc, char *argv[]) root = XRootWindow(display, 0); printf("opened display %p, root window is %d\n", display, root); attributes.event_mask = + LeaveWindowMask | + EnterWindowMask | Button1MotionMask | ButtonPressMask | ButtonReleaseMask | |