mirror of
https://github.com/brl/mutter.git
synced 2024-11-22 16:10:41 -05:00
clutter: Add pad event structs
Those map closely what we get from libinput. Button events have been made its own separate struct, its semantics fall somewhere in between of ClutterButtonEvent and ClutterKeyEvent, so is better emitted as its own set.
This commit is contained in:
parent
1d9d176c3f
commit
b71d7058db
@ -1522,6 +1522,11 @@ typedef enum {
|
||||
CLUTTER_INPUT_DEVICE_TOOL_LENS
|
||||
} ClutterInputDeviceToolType;
|
||||
|
||||
typedef enum {
|
||||
CLUTTER_INPUT_DEVICE_PAD_SOURCE_UNKNOWN,
|
||||
CLUTTER_INPUT_DEVICE_PAD_SOURCE_FINGER,
|
||||
} ClutterInputDevicePadSource;
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __CLUTTER_ENUMS_H__ */
|
||||
|
@ -118,6 +118,9 @@ typedef struct _ClutterTouchEvent ClutterTouchEvent;
|
||||
typedef struct _ClutterTouchpadPinchEvent ClutterTouchpadPinchEvent;
|
||||
typedef struct _ClutterTouchpadSwipeEvent ClutterTouchpadSwipeEvent;
|
||||
typedef struct _ClutterProximityEvent ClutterProximityEvent;
|
||||
typedef struct _ClutterPadButtonEvent ClutterPadButtonEvent;
|
||||
typedef struct _ClutterPadStripEvent ClutterPadStripEvent;
|
||||
typedef struct _ClutterPadRingEvent ClutterPadRingEvent;
|
||||
|
||||
/**
|
||||
* ClutterAnyEvent:
|
||||
@ -493,6 +496,49 @@ struct _ClutterTouchpadSwipeEvent
|
||||
gfloat dy;
|
||||
};
|
||||
|
||||
struct _ClutterPadButtonEvent
|
||||
{
|
||||
ClutterEventType type;
|
||||
guint32 time;
|
||||
ClutterEventFlags flags;
|
||||
ClutterStage *stage;
|
||||
ClutterActor *source;
|
||||
|
||||
guint32 button;
|
||||
guint32 group;
|
||||
ClutterInputDevice *device;
|
||||
};
|
||||
|
||||
struct _ClutterPadStripEvent
|
||||
{
|
||||
ClutterEventType type;
|
||||
guint32 time;
|
||||
ClutterEventFlags flags;
|
||||
ClutterStage *stage;
|
||||
ClutterActor *source;
|
||||
|
||||
ClutterInputDevice *device;
|
||||
ClutterInputDevicePadSource strip_source;
|
||||
guint32 strip_number;
|
||||
guint32 group;
|
||||
gdouble value;
|
||||
};
|
||||
|
||||
struct _ClutterPadRingEvent
|
||||
{
|
||||
ClutterEventType type;
|
||||
guint32 time;
|
||||
ClutterEventFlags flags;
|
||||
ClutterStage *stage;
|
||||
ClutterActor *source;
|
||||
|
||||
ClutterInputDevice *device;
|
||||
ClutterInputDevicePadSource ring_source;
|
||||
guint32 ring_number;
|
||||
guint32 group;
|
||||
gdouble angle;
|
||||
};
|
||||
|
||||
/**
|
||||
* ClutterEvent:
|
||||
*
|
||||
@ -516,6 +562,9 @@ union _ClutterEvent
|
||||
ClutterTouchpadPinchEvent touchpad_pinch;
|
||||
ClutterTouchpadSwipeEvent touchpad_swipe;
|
||||
ClutterProximityEvent proximity;
|
||||
ClutterPadButtonEvent pad_button;
|
||||
ClutterPadStripEvent pad_strip;
|
||||
ClutterPadRingEvent pad_ring;
|
||||
};
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user