@ -78,6 +78,7 @@ struct wlr_seat_pointer_grab;
struct wlr_pointer_grab_interface {
struct wlr_pointer_grab_interface {
void ( * enter ) ( struct wlr_seat_pointer_grab * grab ,
void ( * enter ) ( struct wlr_seat_pointer_grab * grab ,
struct wlr_surface * surface , double sx , double sy ) ;
struct wlr_surface * surface , double sx , double sy ) ;
void ( * clear_focus ) ( struct wlr_seat_pointer_grab * grab ) ;
void ( * motion ) ( struct wlr_seat_pointer_grab * grab , uint32_t time_msec ,
void ( * motion ) ( struct wlr_seat_pointer_grab * grab , uint32_t time_msec ,
double sx , double sy ) ;
double sx , double sy ) ;
uint32_t ( * button ) ( struct wlr_seat_pointer_grab * grab , uint32_t time_msec ,
uint32_t ( * button ) ( struct wlr_seat_pointer_grab * grab , uint32_t time_msec ,
@ -95,6 +96,7 @@ struct wlr_keyboard_grab_interface {
void ( * enter ) ( struct wlr_seat_keyboard_grab * grab ,
void ( * enter ) ( struct wlr_seat_keyboard_grab * grab ,
struct wlr_surface * surface , uint32_t keycodes [ ] ,
struct wlr_surface * surface , uint32_t keycodes [ ] ,
size_t num_keycodes , struct wlr_keyboard_modifiers * modifiers ) ;
size_t num_keycodes , struct wlr_keyboard_modifiers * modifiers ) ;
void ( * clear_focus ) ( struct wlr_seat_keyboard_grab * grab ) ;
void ( * key ) ( struct wlr_seat_keyboard_grab * grab , uint32_t time_msec ,
void ( * key ) ( struct wlr_seat_keyboard_grab * grab , uint32_t time_msec ,
uint32_t key , uint32_t state ) ;
uint32_t key , uint32_t state ) ;
void ( * modifiers ) ( struct wlr_seat_keyboard_grab * grab ,
void ( * modifiers ) ( struct wlr_seat_keyboard_grab * grab ,
@ -354,6 +356,8 @@ void wlr_seat_pointer_enter(struct wlr_seat *wlr_seat,
/**
/**
* Clear the focused surface for the pointer and leave all entered surfaces .
* Clear the focused surface for the pointer and leave all entered surfaces .
* This function does not respect pointer grabs : you probably want
* ` wlr_seat_pointer_notify_clear_focus ( ) ` instead .
*/
*/
void wlr_seat_pointer_clear_focus ( struct wlr_seat * wlr_seat ) ;
void wlr_seat_pointer_clear_focus ( struct wlr_seat * wlr_seat ) ;
@ -399,6 +403,12 @@ void wlr_seat_pointer_send_frame(struct wlr_seat *wlr_seat);
void wlr_seat_pointer_notify_enter ( struct wlr_seat * wlr_seat ,
void wlr_seat_pointer_notify_enter ( struct wlr_seat * wlr_seat ,
struct wlr_surface * surface , double sx , double sy ) ;
struct wlr_surface * surface , double sx , double sy ) ;
/**
* Notify the seat of a pointer leave event to the currently - focused surface .
* Defers to any grab of the pointer .
*/
void wlr_seat_pointer_notify_clear_focus ( struct wlr_seat * wlr_seat ) ;
/**
/**
* Notify the seat of motion over the given surface . Pass surface - local
* Notify the seat of motion over the given surface . Pass surface - local
* coordinates where the pointer motion occurred . Defers to any grab of the
* coordinates where the pointer motion occurred . Defers to any grab of the
@ -485,6 +495,8 @@ void wlr_seat_keyboard_enter(struct wlr_seat *seat,
/**
/**
* Clear the focused surface for the keyboard and leave all entered surfaces .
* Clear the focused surface for the keyboard and leave all entered surfaces .
* This function does not respect keyboard grabs : you probably want
* ` wlr_seat_keyboard_notify_clear_focus ( ) ` instead .
*/
*/
void wlr_seat_keyboard_clear_focus ( struct wlr_seat * wlr_seat ) ;
void wlr_seat_keyboard_clear_focus ( struct wlr_seat * wlr_seat ) ;
@ -511,6 +523,12 @@ void wlr_seat_keyboard_notify_enter(struct wlr_seat *seat,
struct wlr_surface * surface , uint32_t keycodes [ ] , size_t num_keycodes ,
struct wlr_surface * surface , uint32_t keycodes [ ] , size_t num_keycodes ,
struct wlr_keyboard_modifiers * modifiers ) ;
struct wlr_keyboard_modifiers * modifiers ) ;
/**
* Notify the seat of a keyboard leave event to the currently - focused surface .
* Defers to any keyboard grabs .
*/
void wlr_seat_keyboard_notify_clear_focus ( struct wlr_seat * wlr_seat ) ;
/**
/**
* Start a grab of the keyboard of this seat . The grabber is responsible for
* Start a grab of the keyboard of this seat . The grabber is responsible for
* handling all keyboard events until the grab ends .
* handling all keyboard events until the grab ends .