aboutsummaryrefslogtreecommitdiffstats
path: root/sway/input/seat.c
diff options
context:
space:
mode:
authorLibravatar Ryan Dwyer <ryandwyer1@gmail.com>2019-03-16 09:18:54 +1000
committerLibravatar Drew DeVault <sir@cmpwn.com>2019-03-17 10:02:04 -0600
commitfb3475e291ea6be94131c19fdc006e9ad873ea5f (patch)
treeedf7a13eb1ee74f8efd14a8d7b5355f820a8b10a /sway/input/seat.c
parentconfig/output: revamp identifier/name layering (diff)
downloadsway-fb3475e291ea6be94131c19fdc006e9ad873ea5f.tar.gz
sway-fb3475e291ea6be94131c19fdc006e9ad873ea5f.tar.zst
sway-fb3475e291ea6be94131c19fdc006e9ad873ea5f.zip
Replace seatup allows_events with button callback
Diffstat (limited to 'sway/input/seat.c')
-rw-r--r--sway/input/seat.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/sway/input/seat.c b/sway/input/seat.c
index e56a6510..2c9a85c4 100644
--- a/sway/input/seat.c
+++ b/sway/input/seat.c
@@ -1216,6 +1216,14 @@ void seatop_unref(struct sway_seat *seat, struct sway_container *con) {
1216 } 1216 }
1217} 1217}
1218 1218
1219void seatop_button(struct sway_seat *seat, uint32_t time_msec,
1220 struct wlr_input_device *device, uint32_t button,
1221 enum wlr_button_state state) {
1222 if (seat->seatop_impl && seat->seatop_impl->button) {
1223 seat->seatop_impl->button(seat, time_msec, device, button, state);
1224 }
1225}
1226
1219void seatop_motion(struct sway_seat *seat, uint32_t time_msec) { 1227void seatop_motion(struct sway_seat *seat, uint32_t time_msec) {
1220 if (seat->seatop_impl && seat->seatop_impl->motion) { 1228 if (seat->seatop_impl && seat->seatop_impl->motion) {
1221 seat->seatop_impl->motion(seat, time_msec); 1229 seat->seatop_impl->motion(seat, time_msec);
@@ -1246,7 +1254,3 @@ void seatop_render(struct sway_seat *seat, struct sway_output *output,
1246 seat->seatop_impl->render(seat, output, damage); 1254 seat->seatop_impl->render(seat, output, damage);
1247 } 1255 }
1248} 1256}
1249
1250bool seatop_allows_events(struct sway_seat *seat) {
1251 return seat->seatop_impl && seat->seatop_impl->allows_events;
1252}