From ff6f83f05ed177a8e1f706b91fabab7c47b44ab6 Mon Sep 17 00:00:00 2001 From: Carlos Garnacho Date: Tue, 8 Mar 2022 17:03:31 +0100 Subject: [PATCH] clutter: Add ClutterInputCapabilities flagset This will be a truer representation of input devices in the native backend, since a single device can have multiple capabilities. Part-of: --- clutter/clutter/clutter-enums.h | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/clutter/clutter/clutter-enums.h b/clutter/clutter/clutter-enums.h index 9ee55fb5c..99debc1c1 100644 --- a/clutter/clutter/clutter-enums.h +++ b/clutter/clutter/clutter-enums.h @@ -935,6 +935,29 @@ typedef enum /*< prefix=CLUTTER_FLOW >*/ CLUTTER_FLOW_VERTICAL } ClutterFlowOrientation; +/** + * ClutterInputDeviceCapabilities: + * @CLUTTER_INPUT_CAPABILITY_NONE: No capabilities + * @CLUTTER_INPUT_CAPABILITY_POINTER: Pointer capability + * @CLUTTER_INPUT_CAPABILITY_KEYBOARD: Keyboard capability + * @CLUTTER_INPUT_CAPABILITY_TOUCHPAD: Touchpad gesture and scroll capability + * @CLUTTER_INPUT_CAPABILITY_TOUCH: Touch capability + * @CLUTTER_INPUT_CAPABILITY_TABLET_TOOL: Tablet tool capability + * @CLUTTER_INPUT_CAPABILITY_TABLET_PAD: Tablet pad capability + * + * Describes the capabilities of an input device. + **/ +typedef enum /*< prefix=CLUTTER_INPUT_CAPABILITY >*/ +{ + CLUTTER_INPUT_CAPABILITY_NONE = 0, + CLUTTER_INPUT_CAPABILITY_POINTER = 1 << 0, + CLUTTER_INPUT_CAPABILITY_KEYBOARD = 1 << 1, + CLUTTER_INPUT_CAPABILITY_TOUCHPAD = 1 << 2, + CLUTTER_INPUT_CAPABILITY_TOUCH = 1 << 3, + CLUTTER_INPUT_CAPABILITY_TABLET_TOOL = 1 << 4, + CLUTTER_INPUT_CAPABILITY_TABLET_PAD = 1 << 5, +} ClutterInputCapabilities; + /** * ClutterInputDeviceType: * @CLUTTER_POINTER_DEVICE: A pointer device