stage: ensure correct stage is current when picking

_clutter_stage_do_pick called by interactive picking and
clutter_stage_get_actor_at_pos could be accidentally reading back the wrong
actor id's if an other stage has had a more recent render due to animation.

This should resolve some multi stage / ClutterGtk related pick id warnings.
This commit is contained in:
Øyvind Kolås 2011-06-01 22:42:41 +01:00
parent eed1744612
commit ba8cc8e064

View File

@ -1260,6 +1260,7 @@ _clutter_stage_do_pick (ClutterStage *stage,
CLUTTER_TIMER_START (_clutter_uprof_context, pick_timer);
context = _clutter_context_get_default ();
clutter_stage_ensure_current (stage);
/* It's possible that we currently have a static scene and have renderered a
* full, unclipped pick buffer. If so we can simply continue to read from