[PATCH weston] compositor-x11: send pointer frame after axis event

Marek Chalupa mchqwerty at gmail.com
Wed Feb 3 13:03:00 UTC 2016


clients that implement pointer interface of version 5
wait for the frame event, so without it the scrolling
does not work (GTK+ clients do not scroll now for example).
Xcb axis events are discrete, so it's fine to send
frame after every single axis event

Signed-off-by: Marek Chalupa <mchqwerty at gmail.com>
---
 src/compositor-x11.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/compositor-x11.c b/src/compositor-x11.c
index b70c119..13a5d73 100644
--- a/src/compositor-x11.c
+++ b/src/compositor-x11.c
@@ -1092,6 +1092,7 @@ x11_backend_deliver_button_event(struct x11_backend *b,
 			notify_axis(&b->core_seat,
 				    weston_compositor_get_time(),
 				    &weston_event);
+			notify_pointer_frame(&b->core_seat);
 		}
 		return;
 	case 5:
@@ -1104,6 +1105,7 @@ x11_backend_deliver_button_event(struct x11_backend *b,
 			notify_axis(&b->core_seat,
 				    weston_compositor_get_time(),
 				    &weston_event);
+			notify_pointer_frame(&b->core_seat);
 		}
 		return;
 	case 6:
@@ -1116,6 +1118,7 @@ x11_backend_deliver_button_event(struct x11_backend *b,
 			notify_axis(&b->core_seat,
 				    weston_compositor_get_time(),
 				    &weston_event);
+			notify_pointer_frame(&b->core_seat);
 		}
 		return;
 	case 7:
@@ -1128,6 +1131,7 @@ x11_backend_deliver_button_event(struct x11_backend *b,
 			notify_axis(&b->core_seat,
 				    weston_compositor_get_time(),
 				    &weston_event);
+			notify_pointer_frame(&b->core_seat);
 		}
 		return;
 	default:
-- 
2.5.0



More information about the wayland-devel mailing list