@@ -347,6 +347,8 @@ FocusScope {
347347 }
348348
349349 readonly property real virtualKeyboardHeight: root.inputMethodRect.height
350+
351+ property bool anyWindowAnimating: false
350352 }
351353
352354 Component.onCompleted: priv.updateMainAndSideStageIndexes();
@@ -1022,6 +1024,7 @@ FocusScope {
10221024 )
10231025 || appDelegate.fullscreen
10241026 || focusAnimation.running || rightEdgeFocusAnimation.running || hidingAnimation.running
1027+ || priv.anyWindowAnimating // bug #1666363
10251028
10261029 function close() {
10271030 model.window.close();
@@ -1566,11 +1569,12 @@ FocusScope {
15661569 to: ",normal,restored,maximized,maximizedLeft,maximizedRight,maximizedTopLeft,maximizedTopRight,maximizedBottomLeft,maximizedBottomRight,maximizedHorizontally,maximizedVertically,fullscreen"
15671570 enabled: appDelegate.animationsEnabled
15681571 SequentialAnimation {
1572+ ScriptAction { script: { priv.anyWindowAnimating = true; } }
15691573 PropertyAction { target: appDelegate; property: "visuallyMinimized" }
15701574 UbuntuNumberAnimation { target: appDelegate; properties: "requestedX,requestedY,windowedX,windowedY,opacity,scale,requestedWidth,requestedHeight,windowedWidth,windowedHeight";
15711575 duration: priv.animationDuration }
15721576 PropertyAction { target: appDelegate; property: "visuallyMaximized" }
1573− ScriptAction { script: { fakeRectangle.stop(); } }
1577+ ScriptAction { script: { fakeRectangle.stop(); priv.anyWindowAnimating = false; } }
15741578 }
15751579 }
15761580 ]