Represents a Wayland seat and abstracts the underlying capabilities. More...
#include <kanzi/core.ui/platform/input_ng/wayland/wayland_seat.hpp>
Public Member Functions | |
| template<typename T > | |
| bool | addCapabilityListener (const typename T::ListenerType &listener, void *data) const noexcept |
| Adds a listener to a capability. | |
| template<typename T > | |
| bool | hasCapability () const noexcept |
| Checks whether the capability is supported by the current environment. | |
| template<typename T > | |
| void | setCapabilityListener (const typename T::ListenerType &listener, void *data) noexcept |
| Helper function to register a listener for a capability. | |
| void | updateCapabilities (uint32_t capabilityMask, bool platformLoggingEnabled) noexcept |
| Updates the capability status with the provided capability mask. | |
| WaylandSeat (wl_seat *nativeHandle) noexcept | |
| Constructor. | |
Public Member Functions inherited from kanzi::wayland::WaylandInterface< WaylandSeat, wl_seat, wl_seat_listener > | |
| bool | addListener (enable_if_t<!is_same< L, void >::value, const L & > listener, void *data) const noexcept |
| Adds a listener to Wayland object. | |
| KZ_NO_DISCARD unsigned int | askVersion () const noexcept |
| Requests compositor which interface version we use. | |
| KZ_NO_DISCARD wl_seat * | getNativeHandle () const noexcept |
| Gets the underlying native handle. | |
Static Public Attributes | |
| static const uint32_t | s_maxVersion |
| Represents maximum interface version supported by the Wayland implementation that Kanzi libraries were compiled against. | |
| static const wl_interface | s_nativeInterface |
| Represents the underlying native interface. | |
Additional Inherited Members | |
Public Types inherited from kanzi::wayland::WaylandInterface< WaylandSeat, wl_seat, wl_seat_listener > | |
| using | ListenerType |
| Generic alias to query for appropriate listener type. | |
Static Public Member Functions inherited from kanzi::wayland::WaylandInterface< WaylandSeat, wl_seat, wl_seat_listener > | |
| static KZ_NO_DISCARD unsigned int | askVersion (wl_seat *handle) noexcept |
| Requests compositor which interface version we use. | |
Represents a Wayland seat and abstracts the underlying capabilities.
|
explicitnoexcept |
Constructor.
| nativeHandle | Native Wayland handle. |
|
noexcept |
Updates the capability status with the provided capability mask.
| capabilityMask | Capability mask provided by Wayland. |
| platformLoggingEnabled | Indicates whether to produce additional logs. |
Checks whether the capability is supported by the current environment.
| T | Capability type to check. |
|
inlinenoexcept |
Helper function to register a listener for a capability.
This class stores listener internally and reattaches it to the specified capability whenever this capability becomes available. For example, if keyboard becomes unavailable and then available again, registered listener automatically reattaches to that capability.
| T | Capability type for which to register a listener. |
| listener | Listener to register. |
| data | Data pointer to receive when the listener is called. |
|
inlinenoexcept |
Adds a listener to a capability.
| T | Capability type for which to add a listener. |
| listener | Listener to attach. |
| data | Data pointer to receive when the listener is called. |
|
static |
Represents the underlying native interface.
Represents maximum interface version supported by the Wayland implementation that Kanzi libraries were compiled against.
Defines correct maximum possible interface version based on available events and requests.