feat: display on overlay layer only when fs

This commit is contained in:
2 * r + 2 * t 2026-04-30 22:01:27 +10:00
parent d4b98dec77
commit bcd7f6f161

View file

@ -32,11 +32,12 @@ StyledWindow {
return monitor?.activeWorkspace?.toplevels.values.some(t => t.lastIpcObject.fullscreen > 1) ?? false; return monitor?.activeWorkspace?.toplevels.values.some(t => t.lastIpcObject.fullscreen > 1) ?? false;
} }
property real sdfBorderOffset: hasFullscreen ? 2 : 0 // SDFs joins are not exact, so offset by 2px to ensure nothing shows property real fsTransitionProg: hasFullscreen ? 1 : 0
property real borderThickness: hasFullscreen ? 0 : contentItem.Config.border.thickness readonly property real sdfBorderOffset: 2 * fsTransitionProg // SDFs joins are not exact, so offset by 2px to ensure nothing shows
readonly property real borderThickness: contentItem.Config.border.thickness * (1 - fsTransitionProg)
readonly property real borderRounding: contentItem.Config.border.rounding * (1 - fsTransitionProg)
readonly property real shadowOpacity: 0.7 * (1 - fsTransitionProg)
readonly property real borderLayoutThickness: hasFullscreen ? 0 : contentItem.Config.border.thickness readonly property real borderLayoutThickness: hasFullscreen ? 0 : contentItem.Config.border.thickness
property real borderRounding: hasFullscreen ? 0 : contentItem.Config.border.rounding
property real shadowOpacity: hasFullscreen ? 0 : 0.7
readonly property int dragMaskPadding: { readonly property int dragMaskPadding: {
if (focusGrab.active || panels.popouts.isDetached) if (focusGrab.active || panels.popouts.isDetached)
@ -60,7 +61,7 @@ StyledWindow {
name: "drawers" name: "drawers"
WlrLayershell.exclusionMode: ExclusionMode.Ignore WlrLayershell.exclusionMode: ExclusionMode.Ignore
WlrLayershell.layer: WlrLayer.Overlay WlrLayershell.layer: fsTransitionProg > 0 ? WlrLayer.Overlay : WlrLayer.Top
WlrLayershell.keyboardFocus: visibilities.launcher || visibilities.session || panels.dashboard.needsKeyboard ? WlrKeyboardFocus.OnDemand : WlrKeyboardFocus.None WlrLayershell.keyboardFocus: visibilities.launcher || visibilities.session || panels.dashboard.needsKeyboard ? WlrKeyboardFocus.OnDemand : WlrKeyboardFocus.None
mask: hasFullscreen ? emptyRegion : regions mask: hasFullscreen ? emptyRegion : regions
@ -70,28 +71,10 @@ StyledWindow {
anchors.left: true anchors.left: true
anchors.right: true anchors.right: true
Behavior on sdfBorderOffset { Behavior on fsTransitionProg {
Anim {} Anim {}
} }
Behavior on borderThickness {
Anim {
type: Anim.DefaultSpatial
}
}
Behavior on borderRounding {
Anim {
type: Anim.DefaultSpatial
}
}
Behavior on shadowOpacity {
Anim {
type: Anim.DefaultSpatial
}
}
Region { Region {
id: emptyRegion id: emptyRegion
} }