mirror of
https://github.com/brl/mutter.git
synced 2025-02-23 08:24:09 +00:00
drop-action: Use the event propagation macros
This commit is contained in:
parent
81694d0dd9
commit
21149adb12
@ -133,17 +133,17 @@ on_stage_capture (ClutterStage *stage,
|
|||||||
|
|
||||||
if (!(clutter_event_type (event) == CLUTTER_MOTION ||
|
if (!(clutter_event_type (event) == CLUTTER_MOTION ||
|
||||||
clutter_event_type (event) == CLUTTER_BUTTON_RELEASE))
|
clutter_event_type (event) == CLUTTER_BUTTON_RELEASE))
|
||||||
return FALSE;
|
return CLUTTER_EVENT_PROPAGATE;
|
||||||
|
|
||||||
if (!(clutter_event_get_state (event) & CLUTTER_BUTTON1_MASK))
|
if (!(clutter_event_get_state (event) & CLUTTER_BUTTON1_MASK))
|
||||||
return FALSE;
|
return CLUTTER_EVENT_PROPAGATE;
|
||||||
|
|
||||||
clutter_event_get_coords (event, &event_x, &event_y);
|
clutter_event_get_coords (event, &event_x, &event_y);
|
||||||
device = clutter_event_get_device (event);
|
device = clutter_event_get_device (event);
|
||||||
|
|
||||||
drag_actor = _clutter_stage_get_drag_actor (stage, device);
|
drag_actor = _clutter_stage_get_drag_actor (stage, device);
|
||||||
if (drag_actor == NULL)
|
if (drag_actor == NULL)
|
||||||
return FALSE;
|
return CLUTTER_EVENT_PROPAGATE;
|
||||||
|
|
||||||
/* get the actor under the cursor, excluding the dragged actor; we
|
/* get the actor under the cursor, excluding the dragged actor; we
|
||||||
* use reactivity because it won't cause any scene invalidation
|
* use reactivity because it won't cause any scene invalidation
|
||||||
@ -235,7 +235,7 @@ out:
|
|||||||
if (drag_actor != NULL)
|
if (drag_actor != NULL)
|
||||||
clutter_actor_set_reactive (drag_actor, was_reactive);
|
clutter_actor_set_reactive (drag_actor, was_reactive);
|
||||||
|
|
||||||
return FALSE;
|
return CLUTTER_EVENT_PROPAGATE;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
Loading…
x
Reference in New Issue
Block a user