Without adding the keyboard to seat list we wouldn't properly declare
keyboard capability, making the keyboard not work in headless mode.
We actually need to free this at some point so adding to the list is
most sensible, but we still do not want to group virtual keyboards with
regular ones so add a new 'is_virtual' bool to cg_keyboard_group so we
can skip these for grouping.
In headless case there will not be anyone else to call
update_capabilities(), so we must make sure they're called after we add
new devices that could... add capabilities.
Just inconditionally call it like other pointer/keyboard add handlers.
This fixes the following error when trying to map outputs:
00:00:03.384 [../seat.c:126] Input device virtual pointer cannot be mapped to an output device
(this is probably harmless)
together with the previous patch, wayvnc can now be used with cage:
$ cage something
# figure out which wayland socket cage used
$ WAYLAND_DISPLAY=wayland-0 wayvnc
Note this does not appear to work with headless backend, e.g. starting cage with
WLR_BACKENDS=headless WLR_LIBINPUT_NO_DEVICES=1 cage something
does start and wayvnc connects/displays output, but there are tons of errors
and input does not work
Previously, the output of `meson build` would warn about the use of
some functions that have been deprecated since meson v0.56.0, and
the use of the `check` kwarg in the `run_command()` function.
Update meson.build to fix these build warnings.
- Update wlr_box includes to util/box.h: the wlroots header has
been moved upstream.
- Subsurface fields have been moved
- Create renderer and allocator, stop using wlr_backend_get_renderer
- Initalize output rendering
This fixes the drag icon not disappearing when releasing the
pointer button.
Reproduction steps:
- Open gedit
- Drag some text around
- Release the pointer button
view.c:238:52: error: no member named 'subsurfaces' in 'struct wlr_surface'
wl_list_for_each (subsurface, &view->wlr_surface->subsurfaces, parent_link) {
~~~~~~~~~~~~~~~~~ ^
/usr/include/wayland-util.h:443:30: note: expanded from macro 'wl_list_for_each'
for (pos = wl_container_of((head)->next, pos, member); \
^~~~
/usr/include/wayland-util.h:409:32: note: expanded from macro 'wl_container_of'
(__typeof__(sample))((char *)(ptr) - \
^~~
Based on 3162766eef