diff options
author | Drew DeVault <sir@cmpwn.com> | 2017-11-18 14:14:03 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-11-18 14:14:03 -0500 |
commit | fa36ac90f70787176a5cfdb6fa6835aa1226f697 (patch) | |
tree | 5023bac3638960ef0eda89554865e2a612804486 /examples/support | |
parent | 9f552d896f7639fca7914a9313ccb244688349e4 (diff) | |
parent | 458fe633df7827f5b74c034026b6b67045c1e610 (diff) |
Merge pull request #418 from acrisci/feature/wlr-seat-touch
wlr-seat: touch
Diffstat (limited to 'examples/support')
-rw-r--r-- | examples/support/shared.c | 8 | ||||
-rw-r--r-- | examples/support/shared.h | 8 |
2 files changed, 8 insertions, 8 deletions
diff --git a/examples/support/shared.c b/examples/support/shared.c index 07614d86..811c09a6 100644 --- a/examples/support/shared.c +++ b/examples/support/shared.c @@ -136,7 +136,7 @@ static void touch_down_notify(struct wl_listener *listener, void *data) { struct wlr_event_touch_down *event = data; struct touch_state *tstate = wl_container_of(listener, tstate, down); if (tstate->compositor->touch_down_cb) { - tstate->compositor->touch_down_cb(tstate, event->slot, + tstate->compositor->touch_down_cb(tstate, event->touch_id, event->x_mm, event->y_mm, event->width_mm, event->height_mm); } } @@ -145,7 +145,7 @@ static void touch_motion_notify(struct wl_listener *listener, void *data) { struct wlr_event_touch_motion *event = data; struct touch_state *tstate = wl_container_of(listener, tstate, motion); if (tstate->compositor->touch_motion_cb) { - tstate->compositor->touch_motion_cb(tstate, event->slot, + tstate->compositor->touch_motion_cb(tstate, event->touch_id, event->x_mm, event->y_mm, event->width_mm, event->height_mm); } } @@ -154,7 +154,7 @@ static void touch_up_notify(struct wl_listener *listener, void *data) { struct wlr_event_touch_up *event = data; struct touch_state *tstate = wl_container_of(listener, tstate, up); if (tstate->compositor->touch_up_cb) { - tstate->compositor->touch_up_cb(tstate, event->slot); + tstate->compositor->touch_up_cb(tstate, event->touch_id); } } @@ -162,7 +162,7 @@ static void touch_cancel_notify(struct wl_listener *listener, void *data) { struct wlr_event_touch_cancel *event = data; struct touch_state *tstate = wl_container_of(listener, tstate, cancel); if (tstate->compositor->touch_cancel_cb) { - tstate->compositor->touch_cancel_cb(tstate, event->slot); + tstate->compositor->touch_cancel_cb(tstate, event->touch_id); } } diff --git a/examples/support/shared.h b/examples/support/shared.h index cf75f5fe..014b709e 100644 --- a/examples/support/shared.h +++ b/examples/support/shared.h @@ -95,12 +95,12 @@ struct compositor_state { enum wlr_axis_source source, enum wlr_axis_orientation orientation, double delta); - void (*touch_down_cb)(struct touch_state *s, int32_t slot, + void (*touch_down_cb)(struct touch_state *s, int32_t touch_id, double x, double y, double width, double height); - void (*touch_motion_cb)(struct touch_state *s, int32_t slot, + void (*touch_motion_cb)(struct touch_state *s, int32_t touch_id, double x, double y, double width, double height); - void (*touch_up_cb)(struct touch_state *s, int32_t slot); - void (*touch_cancel_cb)(struct touch_state *s, int32_t slot); + void (*touch_up_cb)(struct touch_state *s, int32_t touch_id); + void (*touch_cancel_cb)(struct touch_state *s, int32_t touch_id); void (*tool_axis_cb)(struct tablet_tool_state *s, struct wlr_event_tablet_tool_axis *event); void (*tool_proximity_cb)(struct tablet_tool_state *s, |