mirror of
https://github.com/brl/mutter.git
synced 2024-12-24 12:02:04 +00:00
59f1e531f9
When talking to other applications or serializing the modifier state (and in particular when implementing a wayland compositor), the effective modifier state alone is not sufficient, one needs to know the base, latched and locked modifiers. Previously one could do with backend specific functionality such as clutter_device_manager_evdev_get_xkb_state(), but the problem is that the internal data structures are updated as soon as the events are fetched from the upstream source, but the events are reported to the application some time later, and thus the two can get out of sync. This way, on the other hand, the information is cached in the event, and provided to the application with the value that was current when the event was generated. https://bugzilla.gnome.org/show_bug.cgi?id=706494
35 lines
1.4 KiB
C
35 lines
1.4 KiB
C
#ifndef __CLUTTER_EVENT_PRIVATE_H__
|
|
#define __CLUTTER_EVENT_PRIVATE_H__
|
|
|
|
#include <clutter/clutter-event.h>
|
|
|
|
G_BEGIN_DECLS
|
|
|
|
void _clutter_event_set_pointer_emulated (ClutterEvent *event,
|
|
gboolean is_emulated);
|
|
|
|
/* Reinjecting queued events for processing */
|
|
void _clutter_process_event (ClutterEvent *event);
|
|
|
|
/* clears the event queue inside the main context */
|
|
void _clutter_clear_events_queue (void);
|
|
void _clutter_clear_events_queue_for_stage (ClutterStage *stage);
|
|
|
|
void _clutter_event_set_platform_data (ClutterEvent *event,
|
|
gpointer data);
|
|
gpointer _clutter_event_get_platform_data (const ClutterEvent *event);
|
|
|
|
void _clutter_event_set_state_full (ClutterEvent *event,
|
|
ClutterModifierType button_state,
|
|
ClutterModifierType base_state,
|
|
ClutterModifierType latched_state,
|
|
ClutterModifierType locked_state,
|
|
ClutterModifierType effective_state);
|
|
|
|
void _clutter_event_push (const ClutterEvent *event,
|
|
gboolean do_copy);
|
|
|
|
G_END_DECLS
|
|
|
|
#endif /* __CLUTTER_EVENT_PRIVATE_H__ */
|