mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2026-06-08 04:09:15 -04:00
control center: improve drag handling
misc: fix layer shell enum usage
This commit is contained in:
@@ -156,28 +156,9 @@ PanelWindow {
|
||||
|
||||
visible: !_finalized
|
||||
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)
|
||||
return WlrLayershell.Top;
|
||||
|
||||
SettingsData.notificationOverlayEnabled;
|
||||
|
||||
const shouldUseOverlay = (SettingsData.notificationOverlayEnabled) || (notificationData.urgency === NotificationUrgency.Critical);
|
||||
|
||||
return shouldUseOverlay ? WlrLayershell.Overlay : WlrLayershell.Top;
|
||||
const shouldUseOverlay = notificationData && (SettingsData.notificationOverlayEnabled || notificationData.urgency === NotificationUrgency.Critical);
|
||||
const fallback = shouldUseOverlay ? WlrLayer.Overlay : WlrLayer.Top;
|
||||
return LayerShell.fromEnv("DMS_NOTIFICATION_LAYER", fallback);
|
||||
}
|
||||
WlrLayershell.exclusiveZone: -1
|
||||
WlrLayershell.keyboardFocus: WlrKeyboardFocus.None
|
||||
|
||||
Reference in New Issue
Block a user