lock screen: show clear desktop first, reveal blur and hexes as wave passes
This commit is contained in:
parent
fe02eed625
commit
e4b257d760
2 changed files with 16 additions and 16 deletions
|
|
@ -7,15 +7,8 @@ Item {
|
||||||
|
|
||||||
property bool running: false
|
property bool running: false
|
||||||
property bool reducedMotion: S.Theme.reducedMotion
|
property bool reducedMotion: S.Theme.reducedMotion
|
||||||
property bool overlay: false
|
|
||||||
readonly property real wavePhase: fx.uWavePhase
|
readonly property real wavePhase: fx.uWavePhase
|
||||||
|
|
||||||
Rectangle {
|
|
||||||
anchors.fill: parent
|
|
||||||
color: S.Theme.base01
|
|
||||||
visible: !root.overlay
|
|
||||||
}
|
|
||||||
|
|
||||||
ShaderEffect {
|
ShaderEffect {
|
||||||
id: fx
|
id: fx
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
|
|
|
||||||
|
|
@ -13,16 +13,24 @@ WlSessionLockSurface {
|
||||||
|
|
||||||
color: S.Theme.base00
|
color: S.Theme.base00
|
||||||
|
|
||||||
// Background opacity driven by the first wave sweep across the screen
|
// Wave progress drives blur/dim/hex overlay reveal
|
||||||
property real _unlockFade: 1
|
property real _unlockFade: 1
|
||||||
readonly property real _bgOpacity: (root.width > 0 ? Math.max(0, Math.min(1, _hexWave.wavePhase / root.width)) : 0) * _unlockFade
|
readonly property real _waveProgress: (root.width > 0 ? Math.max(0, Math.min(1, _hexWave.wavePhase / root.width)) : 0) * _unlockFade
|
||||||
|
|
||||||
// Blur screenshot of desktop as background
|
// Clear desktop screenshot - visible immediately
|
||||||
ScreencopyView {
|
ScreencopyView {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
captureSource: root.screen
|
captureSource: root.screen
|
||||||
opacity: root._bgOpacity
|
|
||||||
visible: S.Modules.lock.screenshot ?? true
|
visible: S.Modules.lock.screenshot ?? true
|
||||||
|
opacity: _unlockFade
|
||||||
|
}
|
||||||
|
|
||||||
|
// Blurred screenshot - fades in as wave passes
|
||||||
|
ScreencopyView {
|
||||||
|
anchors.fill: parent
|
||||||
|
captureSource: root.screen
|
||||||
|
visible: S.Modules.lock.screenshot ?? true
|
||||||
|
opacity: root._waveProgress
|
||||||
|
|
||||||
layer.enabled: true
|
layer.enabled: true
|
||||||
layer.effect: MultiEffect {
|
layer.effect: MultiEffect {
|
||||||
|
|
@ -33,20 +41,19 @@ WlSessionLockSurface {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Dim overlay
|
// Dim overlay - fades in with wave
|
||||||
Rectangle {
|
Rectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
color: Qt.rgba(S.Theme.base00.r, S.Theme.base00.g, S.Theme.base00.b, 0.4)
|
color: Qt.rgba(S.Theme.base00.r, S.Theme.base00.g, S.Theme.base00.b, 0.4)
|
||||||
opacity: root._bgOpacity
|
opacity: root._waveProgress
|
||||||
}
|
}
|
||||||
|
|
||||||
// Hex wave overlay - visible immediately so the sweep reveals the background
|
// Hex wave - fades in with wave progress
|
||||||
C.HexWaveBackground {
|
C.HexWaveBackground {
|
||||||
id: _hexWave
|
id: _hexWave
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
running: root.lock.secure
|
running: root.lock.secure
|
||||||
overlay: true
|
opacity: root._waveProgress * 0.4
|
||||||
opacity: 0.4
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Keyboard input via TextInput - engages Qt's full input pipeline including
|
// Keyboard input via TextInput - engages Qt's full input pipeline including
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue