Enable windows to register to get notified when the mouse wheel is scrolled

This commit is contained in:
David Eklov 2016-07-11 23:15:23 -05:00
parent 250ddc66c6
commit c0b7610c26
2 changed files with 29 additions and 1 deletions

View file

@ -27,11 +27,20 @@ struct cursor {
struct wl_poitner *pointer;
};
enum scroll_direction {
SCROLL_UP,
SCROLL_DOWN,
SCROLL_LEFT,
SCROLL_RIGHT,
};
struct pointer_input {
int last_x;
int last_y;
void (*notify_button)(struct window *window, int x, int y, uint32_t button);
void (*notify_scroll)(struct window *window, enum scroll_direction direction);
};
struct window {