mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2026-04-18 06:47:31 -04:00
backend/wayland: Add wlr_wl_backend_set_grab_input_shortcut
Note: For the function to work, keyboard_listener in backend/wayland/seat.c now passes wlr_wl_seat instead of wlr_keyboard by using this function, a compositor can specify a keyboard shortcut that when pressed, will disable the keyboard shortcuts and confine the pointer to the currently focused wayland output, if the system compositor supports these features. Signed-off-by: Lahav T <lahavts@gmail.com>
This commit is contained in:
parent
41494244df
commit
fae0a7d493
5 changed files with 200 additions and 5 deletions
|
|
@ -5,6 +5,7 @@
|
|||
#include <wayland-server-core.h>
|
||||
#include <wlr/backend.h>
|
||||
#include <wlr/types/wlr_output.h>
|
||||
#include <xkbcommon/xkbcommon.h>
|
||||
|
||||
struct wlr_input_device;
|
||||
|
||||
|
|
@ -23,6 +24,15 @@ struct wlr_backend *wlr_wl_backend_create(struct wl_display *display,
|
|||
*/
|
||||
struct wl_display *wlr_wl_backend_get_remote_display(struct wlr_backend *backend);
|
||||
|
||||
/**
|
||||
* Sets the keyboard shortcut for toggle grabbing input of the focused wayland backend output.
|
||||
*
|
||||
* If modifiers_mask and keysym are zero or null, no shortcut will be used.
|
||||
*
|
||||
*/
|
||||
void wlr_wl_backend_set_grab_input_shortcut(struct wlr_backend *backend, uint32_t modifiers_mask,
|
||||
xkb_keysym_t keysym);
|
||||
|
||||
/**
|
||||
* Adds a new output to this backend.
|
||||
*
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue