aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDrew DeVault <sir@cmpwn.com>2018-05-12 09:29:42 -0400
committerGitHub <noreply@github.com>2018-05-12 09:29:42 -0400
commit50922cfe0f1ca71295d331b39d695a62a60650af (patch)
treedb00d6d45676489085e7ebace68415be5c0ab50b /include
parent84609d347a6c943096335ac5c96af133c782e179 (diff)
parentdb84379242cea0283d4031be90dd80a34dd5d2df (diff)
Merge pull request #970 from emersion/pointer-axis-discrete
Add support for discrete axis values and axis source
Diffstat (limited to 'include')
-rw-r--r--include/backend/wayland.h1
-rw-r--r--include/wlr/types/wlr_pointer.h1
-rw-r--r--include/wlr/types/wlr_seat.h9
3 files changed, 8 insertions, 3 deletions
diff --git a/include/backend/wayland.h b/include/backend/wayland.h
index fda27da9..46f18c84 100644
--- a/include/backend/wayland.h
+++ b/include/backend/wayland.h
@@ -72,6 +72,7 @@ struct wlr_wl_pointer {
struct wlr_wl_input_device *input_device;
struct wl_pointer *wl_pointer;
enum wlr_axis_source axis_source;
+ int32_t axis_discrete;
struct wlr_wl_output *output;
struct wl_listener output_destroy;
diff --git a/include/wlr/types/wlr_pointer.h b/include/wlr/types/wlr_pointer.h
index 45619e0a..48c89151 100644
--- a/include/wlr/types/wlr_pointer.h
+++ b/include/wlr/types/wlr_pointer.h
@@ -58,6 +58,7 @@ struct wlr_event_pointer_axis {
enum wlr_axis_source source;
enum wlr_axis_orientation orientation;
double delta;
+ int32_t delta_discrete;
};
#endif
diff --git a/include/wlr/types/wlr_seat.h b/include/wlr/types/wlr_seat.h
index e1fa27bb..f4840c89 100644
--- a/include/wlr/types/wlr_seat.h
+++ b/include/wlr/types/wlr_seat.h
@@ -60,7 +60,8 @@ struct wlr_pointer_grab_interface {
uint32_t (*button)(struct wlr_seat_pointer_grab *grab, uint32_t time,
uint32_t button, uint32_t state);
void (*axis)(struct wlr_seat_pointer_grab *grab, uint32_t time,
- enum wlr_axis_orientation orientation, double value);
+ enum wlr_axis_orientation orientation, double value,
+ int32_t value_discrete, enum wlr_axis_source source);
void (*cancel)(struct wlr_seat_pointer_grab *grab);
};
@@ -300,7 +301,8 @@ uint32_t wlr_seat_pointer_send_button(struct wlr_seat *wlr_seat, uint32_t time,
* grabs.
**/
void wlr_seat_pointer_send_axis(struct wlr_seat *wlr_seat, uint32_t time,
- enum wlr_axis_orientation orientation, double value);
+ enum wlr_axis_orientation orientation, double value,
+ int32_t value_discrete, enum wlr_axis_source source);
/**
* Start a grab of the pointer of this seat. The grabber is responsible for
@@ -341,7 +343,8 @@ uint32_t wlr_seat_pointer_notify_button(struct wlr_seat *wlr_seat,
* Notify the seat of an axis event.
*/
void wlr_seat_pointer_notify_axis(struct wlr_seat *wlr_seat, uint32_t time,
- enum wlr_axis_orientation orientation, double value);
+ enum wlr_axis_orientation orientation, double value,
+ int32_t value_discrete, enum wlr_axis_source source);
/**
* Whether or not the pointer has a grab other than the default grab.