mirror of
https://github.com/edu4rdshl/gnome-shell.git
synced 2026-07-18 07:34:54 +00:00
workspace: Don't unfreeze layout during overview animation
During overview closing animation the allocation expands more or less every frame. Unfreezing the layout then leads to windows snapping to their new position if e.g. a window was closed which doesn't look nice. Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3216 Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1550>
This commit is contained in:
parent
8f9cc4b5c2
commit
d82dcd6f67
1 changed files with 7 additions and 2 deletions
|
|
@ -566,8 +566,13 @@ var WorkspaceLayout = GObject.registerClass({
|
|||
this._lastBox = containerBox.copy();
|
||||
|
||||
// If the containers size changed, we can no longer keep around
|
||||
// the old windowSlots, so we must unfreeze the layout
|
||||
if (this._layoutFrozen && containerAllocationChanged) {
|
||||
// the old windowSlots, so we must unfreeze the layout.
|
||||
//
|
||||
// However, if the overview animation is in progress, don't unfreeze
|
||||
// the layout. This is needed to prevent windows "snapping" to their
|
||||
// new positions during the overview closing animation when the
|
||||
// allocation subtly expands every frame.
|
||||
if (this._layoutFrozen && containerAllocationChanged && !Main.overview.animationInProgress) {
|
||||
this._layoutFrozen = false;
|
||||
this.notify('layout-frozen');
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue