[vlc-devel] [PATCH 13/27] qml: make StackViewExt transition animation smooth & lower the duration

Fatih Uzunoglu fuzun54 at outlook.com
Fri Dec 4 00:01:48 CET 2020


This patch fixes the annoying transition effect of StackViewExt. With sine easing, it is smoother even at half duration.
---
 modules/gui/qt/widgets/qml/StackViewExt.qml | 14 ++++++++------
 1 file changed, 8 insertions(+), 6 deletions(-)

diff --git a/modules/gui/qt/widgets/qml/StackViewExt.qml b/modules/gui/qt/widgets/qml/StackViewExt.qml
index 16e93e01d2..7bceef3f95 100644
--- a/modules/gui/qt/widgets/qml/StackViewExt.qml
+++ b/modules/gui/qt/widgets/qml/StackViewExt.qml
@@ -29,18 +29,20 @@ StackView {
     replaceEnter: Transition {
         PropertyAnimation {
             property: "opacity"
-            from: 0
-            to:1
-            duration: 500
+            from: 0.0
+            to: 1.0
+            duration: 250
+            easing.type: Easing.InSine
         }
     }
 
     replaceExit: Transition {
         PropertyAnimation {
             property: "opacity"
-            from: 1
-            to:0
-            duration: 500
+            from: 1.0
+            to: 0.0
+            duration: 250
+            easing.type: Easing.OutSine
         }
     }
 
-- 
2.27.0



More information about the vlc-devel mailing list