From 36ff18bfe350b7565497c297cdfa1727e89e52dc Mon Sep 17 00:00:00 2001 From: end-4 <97237370+end-4@users.noreply.github.com> Date: Mon, 15 Dec 2025 00:31:22 +0100 Subject: [PATCH] waffles: lock: open anim --- .../modules/common/panels/lock/LockScreen.qml | 1 - .../ii/modules/waffle/lock/WaffleLock.qml | 48 +++++++++++++++++-- 2 files changed, 43 insertions(+), 6 deletions(-) diff --git a/dots/.config/quickshell/ii/modules/common/panels/lock/LockScreen.qml b/dots/.config/quickshell/ii/modules/common/panels/lock/LockScreen.qml index 9e4b9bd94..5a1b24d7e 100644 --- a/dots/.config/quickshell/ii/modules/common/panels/lock/LockScreen.qml +++ b/dots/.config/quickshell/ii/modules/common/panels/lock/LockScreen.qml @@ -92,7 +92,6 @@ Scope { WlSessionLock { id: lock locked: GlobalStates.screenLocked - surface: root.sessionLockSurface } diff --git a/dots/.config/quickshell/ii/modules/waffle/lock/WaffleLock.qml b/dots/.config/quickshell/ii/modules/waffle/lock/WaffleLock.qml index 581ce9152..b1ff6f353 100644 --- a/dots/.config/quickshell/ii/modules/waffle/lock/WaffleLock.qml +++ b/dots/.config/quickshell/ii/modules/waffle/lock/WaffleLock.qml @@ -36,15 +36,34 @@ LockScreen { Image { id: bg z: 0 - anchors.fill: parent + width: parent.width + height: parent.height + onStatusChanged: { + if (status === Image.Ready) { + print("Lock wallpaper loaded"); + print(lockSurfaceItem.height); + y = -lockSurfaceItem.height; + openAnim.restart(); + } + } sourceSize: Qt.size(lockSurfaceItem.width, lockSurfaceItem.height) source: Config.options.background.wallpaperPath fillMode: Image.PreserveAspectCrop + + PropertyAnimation { + id: openAnim + target: bg + property: "y" + to: 0 + duration: 350 + easing.type: Easing.BezierSpline + easing.bezierCurve: Looks.transition.easing.bezierCurve.easeIn + } } GaussianBlur { z: 1 - anchors.fill: parent + anchors.fill: bg source: bg radius: 100 samples: radius * 2 + 1 @@ -67,7 +86,7 @@ LockScreen { Interactables { id: interactables z: 2 - anchors.fill: parent + anchors.fill: bg } } @@ -83,12 +102,31 @@ LockScreen { // } function switchToFocusedView() { - root.passwordView = true; + switchToPasswordViewAnim.restart(); + } + + SequentialAnimation { + id: switchToPasswordViewAnim + PropertyAnimation { + target: unfocusedContent + property: "y" + from: 0 + to: -height * 1.1 + duration: 250 + easing.type: Easing.BezierSpline + easing.bezierCurve: Looks.transition.easing.bezierCurve.easeIn + } + ScriptAction { + script: { + root.passwordView = true; + } + } } Item { id: unfocusedContent - anchors.fill: parent + width: parent.width + height: parent.height visible: !root.passwordView ClockTextGroup { anchors {