From b107295c03a8c82ecc6ba38fce62a38fec409bae Mon Sep 17 00:00:00 2001 From: Xaver Hugl Date: Thu, 13 Jun 2024 01:41:55 +0200 Subject: [PATCH] windowheap: don't animate the position of windows that get hidden The target position is zero, so they just move into the top left corner, which looks weird. With this commit, they just fade away without moving --- src/plugins/private/qml/WindowHeapDelegate.qml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/plugins/private/qml/WindowHeapDelegate.qml b/src/plugins/private/qml/WindowHeapDelegate.qml index b1b2620efd..5713ca25e2 100644 --- a/src/plugins/private/qml/WindowHeapDelegate.qml +++ b/src/plugins/private/qml/WindowHeapDelegate.qml @@ -226,10 +226,10 @@ Item { name: "partial" PropertyChanges { target: thumb - x: (thumb.window.x - targetScreen.geometry.x - (thumb.windowHeap.absolutePositioning ? windowHeap.layout.Kirigami.ScenePosition.x : 0)) * (1 - thumb.partialActivationFactor) + cell.x * thumb.partialActivationFactor - y: (thumb.window.y - targetScreen.geometry.y - (thumb.windowHeap.absolutePositioning ? windowHeap.layout.Kirigami.ScenePosition.y : 0)) * (1 - thumb.partialActivationFactor) + cell.y * thumb.partialActivationFactor - width: thumb.window.width * (1 - thumb.partialActivationFactor) + cell.width * thumb.partialActivationFactor - height: thumb.window.height * (1 - thumb.partialActivationFactor) + cell.height * thumb.partialActivationFactor + x: (thumb.window.x - targetScreen.geometry.x - (thumb.windowHeap.absolutePositioning ? windowHeap.layout.Kirigami.ScenePosition.x : 0)) * (thumb.activeHidden ? 1 : 1 - thumb.partialActivationFactor) + (thumb.activeHidden ? 0 : cell.x * thumb.partialActivationFactor) + y: (thumb.window.y - targetScreen.geometry.y - (thumb.windowHeap.absolutePositioning ? windowHeap.layout.Kirigami.ScenePosition.y : 0)) * (thumb.activeHidden ? 1 : 1 - thumb.partialActivationFactor) + (thumb.activeHidden ? 0 : cell.y * thumb.partialActivationFactor) + width: thumb.window.width * (thumb.activeHidden ? 1 : 1 - thumb.partialActivationFactor) + cell.width * (thumb.activeHidden ? 0 : thumb.partialActivationFactor) + height: thumb.window.height * (thumb.activeHidden ? 1 : 1 - thumb.partialActivationFactor) + cell.height * (thumb.activeHidden ? 0 : thumb.partialActivationFactor) opacity: thumb.initialHidden ? (thumb.activeHidden ? 0 : thumb.partialActivationFactor) : (thumb.activeHidden ? 1 - thumb.partialActivationFactor : 1)