[gnome-shell/gnome-41] layout: Make sure startup animation completes



commit d89fc4ba615efa8ac819df412d1c510274535842
Author: Florian Müllner <fmuellner gnome org>
Date:   Wed Apr 13 20:57:05 2022 +0200

    layout: Make sure startup animation completes
    
    We currently complete the animation using an onComplete handler,
    which only runs if the corresponding transition was stopped when
    finished.
    
    While it is unexpected that the transition is interrupted, it can
    apparently happen under some circumstances (like VMs with qlx).
    The consequences of that are pretty bad, mainly due to the cover
    pane that prevents input during the animation not getting removed.
    
    Address this by always completing the animation when the transition
    is stopped, regardless of whether it completed or not.
    
    https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/5337
    
    Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2269>
    (cherry picked from commit e69da36095d5093c1c7bec7a9c96c079c0b837f9)

 js/ui/layout.js | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/js/ui/layout.js b/js/ui/layout.js
index 951c42fb8d..f9c3c09eb0 100644
--- a/js/ui/layout.js
+++ b/js/ui/layout.js
@@ -704,14 +704,14 @@ var LayoutManager = GObject.registerClass({
             translation_y: 0,
             duration: STARTUP_ANIMATION_TIME,
             mode: Clutter.AnimationMode.EASE_OUT_QUAD,
-            onComplete: () => this._startupAnimationComplete(),
+            onStopped: () => this._startupAnimationComplete(),
         });
     }
 
     _startupAnimationSession() {
-        const onComplete = () => this._startupAnimationComplete();
+        const onStopped = () => this._startupAnimationComplete();
         if (Main.sessionMode.hasOverview) {
-            Main.overview.runStartupAnimation(onComplete);
+            Main.overview.runStartupAnimation(onStopped);
         } else {
             this.uiGroup.ease({
                 scale_x: 1,
@@ -719,7 +719,7 @@ var LayoutManager = GObject.registerClass({
                 opacity: 255,
                 duration: STARTUP_ANIMATION_TIME,
                 mode: Clutter.AnimationMode.EASE_OUT_QUAD,
-                onComplete,
+                onStopped,
             });
         }
     }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]