mirror of
https://github.com/brl/mutter.git
synced 2024-12-26 12:52:14 +00:00
clutter: Pass stage to emit_event()
Avoid poking at the event field, and use an explicit parameter. Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3153>
This commit is contained in:
parent
b52aa487c8
commit
e648ef7980
@ -682,13 +682,14 @@ _clutter_boolean_continue_accumulator (GSignalInvocationHint *ihint,
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
static inline void
|
static inline void
|
||||||
emit_event (ClutterEvent *event)
|
emit_event (ClutterStage *stage,
|
||||||
|
ClutterEvent *event)
|
||||||
{
|
{
|
||||||
if (event->type == CLUTTER_KEY_PRESS ||
|
if (event->type == CLUTTER_KEY_PRESS ||
|
||||||
event->type == CLUTTER_KEY_RELEASE)
|
event->type == CLUTTER_KEY_RELEASE)
|
||||||
cally_snoop_key_event ((ClutterKeyEvent *) event);
|
cally_snoop_key_event ((ClutterKeyEvent *) event);
|
||||||
|
|
||||||
clutter_stage_emit_event (event->any.stage, event);
|
clutter_stage_emit_event (stage, event);
|
||||||
}
|
}
|
||||||
|
|
||||||
static ClutterActor *
|
static ClutterActor *
|
||||||
@ -876,7 +877,7 @@ _clutter_process_event_details (ClutterActor *stage,
|
|||||||
case CLUTTER_TOUCH_END:
|
case CLUTTER_TOUCH_END:
|
||||||
case CLUTTER_PROXIMITY_IN:
|
case CLUTTER_PROXIMITY_IN:
|
||||||
case CLUTTER_PROXIMITY_OUT:
|
case CLUTTER_PROXIMITY_OUT:
|
||||||
emit_event (event);
|
emit_event (CLUTTER_STAGE (stage), event);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case CLUTTER_DEVICE_REMOVED:
|
case CLUTTER_DEVICE_REMOVED:
|
||||||
|
Loading…
Reference in New Issue
Block a user