mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2026-01-24 21:42:51 -05:00
add modal and notification layer overrides
This commit is contained in:
@@ -75,7 +75,18 @@ PanelWindow {
|
|||||||
|
|
||||||
visible: shouldBeVisible
|
visible: shouldBeVisible
|
||||||
color: "transparent"
|
color: "transparent"
|
||||||
WlrLayershell.layer: WlrLayershell.Top // if set to overlay -> virtual keyboards can be stuck under modal
|
WlrLayershell.layer: {
|
||||||
|
switch (Quickshell.env("DMS_MODAL_LAYER")) {
|
||||||
|
case "bottom":
|
||||||
|
return WlrLayershell.Bottom
|
||||||
|
case "overlay":
|
||||||
|
return WlrLayershell.Overlay
|
||||||
|
case "background":
|
||||||
|
return WlrLayershell.Background
|
||||||
|
default:
|
||||||
|
return WlrLayershell.Top
|
||||||
|
}
|
||||||
|
}
|
||||||
WlrLayershell.exclusiveZone: -1
|
WlrLayershell.exclusiveZone: -1
|
||||||
WlrLayershell.keyboardFocus: shouldHaveFocus ? WlrKeyboardFocus.Exclusive : WlrKeyboardFocus.None
|
WlrLayershell.keyboardFocus: shouldHaveFocus ? WlrKeyboardFocus.Exclusive : WlrKeyboardFocus.None
|
||||||
onVisibleChanged: {
|
onVisibleChanged: {
|
||||||
|
|||||||
@@ -64,6 +64,20 @@ PanelWindow {
|
|||||||
|
|
||||||
visible: hasValidData
|
visible: hasValidData
|
||||||
WlrLayershell.layer: {
|
WlrLayershell.layer: {
|
||||||
|
const envLayer = Quickshell.env("DMS_NOTIFICATION_LAYER")
|
||||||
|
if (envLayer) {
|
||||||
|
switch (envLayer) {
|
||||||
|
case "bottom":
|
||||||
|
return WlrLayershell.Bottom
|
||||||
|
case "overlay":
|
||||||
|
return WlrLayershell.Overlay
|
||||||
|
case "background":
|
||||||
|
return WlrLayershell.Background
|
||||||
|
case "top":
|
||||||
|
return WlrLayershell.Top
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (!notificationData)
|
if (!notificationData)
|
||||||
return WlrLayershell.Top
|
return WlrLayershell.Top
|
||||||
|
|
||||||
|
|||||||
@@ -65,7 +65,18 @@ PanelWindow {
|
|||||||
}
|
}
|
||||||
|
|
||||||
color: "transparent"
|
color: "transparent"
|
||||||
WlrLayershell.layer: WlrLayershell.Top
|
WlrLayershell.layer: {
|
||||||
|
switch (Quickshell.env("DMS_DANKBAR_LAYER")) {
|
||||||
|
case "bottom":
|
||||||
|
return WlrLayershell.Bottom
|
||||||
|
case "overlay":
|
||||||
|
return WlrLayershell.Overlay
|
||||||
|
case "background":
|
||||||
|
return WlrLayershell.Background
|
||||||
|
default:
|
||||||
|
return WlrLayershell.Top
|
||||||
|
}
|
||||||
|
}
|
||||||
WlrLayershell.exclusiveZone: -1
|
WlrLayershell.exclusiveZone: -1
|
||||||
WlrLayershell.keyboardFocus: shouldBeVisible ? keyboardFocusMode : WlrKeyboardFocus.None
|
WlrLayershell.keyboardFocus: shouldBeVisible ? keyboardFocusMode : WlrKeyboardFocus.None
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user