Skip to content

Require devices to be within EIS-allocated seats

Peter Hutterer requested to merge whot/libei:wip/seats-v2 into master

This replaces !10 (closed) with what is IMO a better approach. !10 (closed) tried to solve the seat assignment by having the client "guess" what seat to assign (or none) and the server change/unseat that guesswork.

The approach here is basically how Wayland/Xorg already work, seats are allocated by the server. After a client is connected, an EIS server may send one or more SEAT_ADDED events. A client can then add devices to those seats, so any device is automatically bound to a seat and the server controls exactly which seats are visible to the client. The seat has a capabilities mask too, so the client knows there is no point in trying to create touch devices if the seat we got doesn't have the touch capability set (the server can still drop a capability on any individual device regardless).

Seats can be added/removed any time, the library takes care of generating the right device removals where necessary.

WIP because it's missing a few test cases and bits and bobs, but the major restructuring is done.

cc @ofourdan, @emersion, @jadahl

Edited by Peter Hutterer

Merge request reports