Drop the wallpaper picker from the notch in notch mode
In notch mode the picker grows from the screen's top edge in the notch's shape, with the notch's open fill and opening/closing speeds, and the collapsed notch hides while it is up. Bar mode is unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
cc0bc0a72f
commit
ea8fc29544
3 files changed
+17
-5
No files matched your search
@@ -112,6 +112,6 @@ PanelWindow {
|
|||||||
width: implicitWidth
|
width: implicitWidth
|
||||||
height: implicitHeight
|
height: implicitHeight
|
||||||
// The open notch window draws over this spot on its own screen.
|
// The open notch window draws over this spot on its own screen.
|
||||||
visible: root.notch && !(ShellState.notchWindow && ShellState.notchWindow.visible && ShellState.notchWindow.screen === root.screen) && !(ShellState.launcherOpen && ScreenService.current(ShellState.launcherScreen) === root.screen)
|
visible: root.notch && !(ShellState.notchWindow && ShellState.notchWindow.visible && ShellState.notchWindow.screen === root.screen) && !(ShellState.launcherOpen && ScreenService.current(ShellState.launcherScreen) === root.screen) && !(ShellState.wallpaperWindow && ShellState.wallpaperWindow.visible && ShellState.wallpaperWindow.screen === root.screen)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -21,6 +21,10 @@ Item {
|
|||||||
// "slide" unrolls out of the bar; "drop" falls into place and away
|
// "slide" unrolls out of the bar; "drop" falls into place and away
|
||||||
// downwards; "fade" fades in place; "shrink" grows from / shrinks to nothing.
|
// downwards; "fade" fades in place; "shrink" grows from / shrinks to nothing.
|
||||||
property string style: "slide"
|
property string style: "slide"
|
||||||
|
// Fill and timing; notch mode passes the notch's own.
|
||||||
|
property color fillColor: Qt.alpha(Theme.surface, Theme.glassOpacity)
|
||||||
|
property real openDuration: Theme.duration * 1.8
|
||||||
|
property real closeDuration: Theme.duration
|
||||||
readonly property bool unrolls: style === "slide"
|
readonly property bool unrolls: style === "slide"
|
||||||
property real progress: open ? 1 : 0
|
property real progress: open ? 1 : 0
|
||||||
readonly property real revealed: unrolls ? Math.max(0, contentHeight * progress) : contentHeight
|
readonly property real revealed: unrolls ? Math.max(0, contentHeight * progress) : contentHeight
|
||||||
@@ -39,7 +43,7 @@ Item {
|
|||||||
Behavior on progress {
|
Behavior on progress {
|
||||||
NumberAnimation {
|
NumberAnimation {
|
||||||
id: anim
|
id: anim
|
||||||
duration: root.open ? Theme.duration * 1.8 : Theme.duration
|
duration: root.open ? root.openDuration : root.closeDuration
|
||||||
easing.type: Easing.BezierSpline
|
easing.type: Easing.BezierSpline
|
||||||
easing.bezierCurve: root.open ? [0.05, 0.7, 0.1, 1, 1, 1] : [0.3, 0, 0.8, 0.15, 1, 1]
|
easing.bezierCurve: root.open ? [0.05, 0.7, 0.1, 1, 1, 1] : [0.3, 0, 0.8, 0.15, 1, 1]
|
||||||
}
|
}
|
||||||
@@ -77,6 +81,7 @@ Item {
|
|||||||
bodyHeight: root.revealed
|
bodyHeight: root.revealed
|
||||||
ear: BarDrawers.ear
|
ear: BarDrawers.ear
|
||||||
attached: root.attached
|
attached: root.attached
|
||||||
|
fillColor: root.fillColor
|
||||||
}
|
}
|
||||||
Item {
|
Item {
|
||||||
id: hit
|
id: hit
|
||||||
|
|||||||
@@ -19,7 +19,11 @@ PanelWindow {
|
|||||||
readonly property real screenWidth:screen ? screen.width : 1920
|
readonly property real screenWidth:screen ? screen.width : 1920
|
||||||
readonly property real screenHeight:screen ? screen.height : 1080
|
readonly property real screenHeight:screen ? screen.height : 1080
|
||||||
implicitWidth:Math.round(surface.width)
|
implicitWidth:Math.round(surface.width)
|
||||||
implicitHeight:Math.round(BarDrawers.bottom+surface.contentHeight)
|
// Notch mode: no bar to hang from, so it drops from the screen's top edge
|
||||||
|
// in the notch's shape, colour and speeds.
|
||||||
|
readonly property bool notch:ShellState.notchMode
|
||||||
|
readonly property real top:notch ? 0 : BarDrawers.bottom
|
||||||
|
implicitHeight:Math.round(top+surface.contentHeight)
|
||||||
visible:ShellState.wallpaperPickerOpen || surface.shown
|
visible:ShellState.wallpaperPickerOpen || surface.shown
|
||||||
color:Theme.transparent
|
color:Theme.transparent
|
||||||
exclusionMode:ExclusionMode.Ignore
|
exclusionMode:ExclusionMode.Ignore
|
||||||
@@ -107,10 +111,13 @@ PanelWindow {
|
|||||||
BarDrawer {
|
BarDrawer {
|
||||||
id:surface
|
id:surface
|
||||||
objectName:"wallpaperPickerSurface"
|
objectName:"wallpaperPickerSurface"
|
||||||
y:BarDrawers.bottom
|
y:root.top
|
||||||
open:ShellState.wallpaperPickerOpen
|
open:ShellState.wallpaperPickerOpen
|
||||||
contentWidth:Math.min(1240,root.screenWidth-2*(BarDrawers.margin+BarDrawers.radius+ear))
|
contentWidth:Math.min(1240,root.screenWidth-2*(BarDrawers.margin+BarDrawers.radius+ear))
|
||||||
contentHeight:Math.min(640,root.screenHeight-BarDrawers.bottom-40)
|
contentHeight:Math.min(640,root.screenHeight-root.top-40)
|
||||||
|
fillColor:root.notch ? Theme.notchOpenFill : Qt.alpha(Theme.surface,Theme.glassOpacity)
|
||||||
|
openDuration:root.notch ? Theme.notchOpenDuration*2 : Theme.duration*1.8
|
||||||
|
closeDuration:root.notch ? Theme.notchCloseDuration*1.3 : Theme.duration
|
||||||
drawerId:"wallpaper"
|
drawerId:"wallpaper"
|
||||||
screenName:root.screen ? root.screen.name : ""
|
screenName:root.screen ? root.screen.name : ""
|
||||||
screenX:(root.screenWidth-width)/2
|
screenX:(root.screenWidth-width)/2
|
||||||
|
|||||||
Reference in new issue
Block a user