mirror of
https://github.com/brl/mutter.git
synced 2024-12-23 03:22:04 +00:00
clutter: Defer actor allocations till shown
Currently nothing in the clutter machinery prevents hidden portions of the actor tree from calling queue_relayout() (and having it fully honored). But that allocation should not be necessary till the actor is shown, and one of the things we do on show() is queueing a relayout/redraw after flagging the actor as visible. We can simply defer clutter_actor_allocate() calls till that show() call, and leave the needs_allocate and other flags set so we ensure the allocation is properly set then. This should cut down some needless operations when invisible portions of the actor tree change indirectly due to user interaction, or due to background activity. https://gitlab.gnome.org/GNOME/mutter/merge_requests/677
This commit is contained in:
parent
dd8c8e82f2
commit
0eab73dc2e
@ -10107,6 +10107,9 @@ clutter_actor_allocate (ClutterActor *self,
|
||||
return;
|
||||
}
|
||||
|
||||
if (!clutter_actor_is_visible (self))
|
||||
return;
|
||||
|
||||
priv = self->priv;
|
||||
|
||||
old_allocation = priv->allocation;
|
||||
|
Loading…
Reference in New Issue
Block a user