mirror of
https://github.com/brl/mutter.git
synced 2024-11-25 09:30:45 -05:00
clutter/stage: Move out tracing from do_update() to callees
This makes the function a bit more cluttered, and it'll always trace when the same functions are called from other places. https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1285
This commit is contained in:
parent
b9a52ecfdf
commit
14dfe929f2
@ -1218,6 +1218,8 @@ _clutter_stage_maybe_relayout (ClutterActor *actor)
|
|||||||
if (priv->pending_relayouts == NULL)
|
if (priv->pending_relayouts == NULL)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
COGL_TRACE_BEGIN_SCOPED (ClutterStageRelayout, "Layout");
|
||||||
|
|
||||||
CLUTTER_NOTE (ACTOR, ">>> Recomputing layout");
|
CLUTTER_NOTE (ACTOR, ">>> Recomputing layout");
|
||||||
|
|
||||||
stolen_list = g_steal_pointer (&priv->pending_relayouts);
|
stolen_list = g_steal_pointer (&priv->pending_relayouts);
|
||||||
@ -1266,6 +1268,8 @@ clutter_stage_do_redraw (ClutterStage *stage)
|
|||||||
if (priv->impl == NULL)
|
if (priv->impl == NULL)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
COGL_TRACE_BEGIN_SCOPED (ClutterStagePaint, "Paint");
|
||||||
|
|
||||||
CLUTTER_NOTE (PAINT, "Redraw started for stage '%s'[%p]",
|
CLUTTER_NOTE (PAINT, "Redraw started for stage '%s'[%p]",
|
||||||
_clutter_actor_get_debug_name (actor),
|
_clutter_actor_get_debug_name (actor),
|
||||||
stage);
|
stage);
|
||||||
@ -1421,12 +1425,8 @@ _clutter_stage_do_update (ClutterStage *stage)
|
|||||||
* check or clear the pending redraws flag since a relayout may
|
* check or clear the pending redraws flag since a relayout may
|
||||||
* queue a redraw.
|
* queue a redraw.
|
||||||
*/
|
*/
|
||||||
COGL_TRACE_BEGIN (ClutterStageRelayout, "Layout");
|
|
||||||
|
|
||||||
_clutter_stage_maybe_relayout (CLUTTER_ACTOR (stage));
|
_clutter_stage_maybe_relayout (CLUTTER_ACTOR (stage));
|
||||||
|
|
||||||
COGL_TRACE_END (ClutterStageRelayout);
|
|
||||||
|
|
||||||
if (!priv->redraw_pending)
|
if (!priv->redraw_pending)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
@ -1435,13 +1435,9 @@ _clutter_stage_do_update (ClutterStage *stage)
|
|||||||
|
|
||||||
update_actor_stage_views (stage);
|
update_actor_stage_views (stage);
|
||||||
|
|
||||||
COGL_TRACE_BEGIN (ClutterStagePaint, "Paint");
|
|
||||||
|
|
||||||
clutter_stage_maybe_finish_queue_redraws (stage);
|
clutter_stage_maybe_finish_queue_redraws (stage);
|
||||||
clutter_stage_do_redraw (stage);
|
clutter_stage_do_redraw (stage);
|
||||||
|
|
||||||
COGL_TRACE_END (ClutterStagePaint);
|
|
||||||
|
|
||||||
/* reset the guard, so that new redraws are possible */
|
/* reset the guard, so that new redraws are possible */
|
||||||
priv->redraw_pending = FALSE;
|
priv->redraw_pending = FALSE;
|
||||||
|
|
||||||
@ -3362,6 +3358,8 @@ clutter_stage_maybe_finish_queue_redraws (ClutterStage *stage)
|
|||||||
{
|
{
|
||||||
ClutterStagePrivate *priv = stage->priv;
|
ClutterStagePrivate *priv = stage->priv;
|
||||||
|
|
||||||
|
COGL_TRACE_BEGIN_SCOPED (ClutterStageFinishQueueRedraws, "FinishQueueRedraws");
|
||||||
|
|
||||||
if (!priv->pending_finish_queue_redraws)
|
if (!priv->pending_finish_queue_redraws)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user