1
0
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:
bbedward
2026-06-01 13:13:17 -04:00
parent 0a668df138
commit 8c20f448ed
20 changed files with 634 additions and 208 deletions
+1 -13
View File
@@ -1,5 +1,4 @@
import QtQuick
import Quickshell
import qs.Common
import qs.Services
import qs.Widgets
@@ -39,18 +38,7 @@ Item {
readonly property real rightMargin: !isVerticalOrientation ? (isRightBarEdge && isLast ? barEdgeExtension : (isLast ? gapExtension : gapExtension / 2)) : 0
readonly property real topMargin: isVerticalOrientation ? (isTopBarEdge && isFirst ? barEdgeExtension : (isFirst ? gapExtension : gapExtension / 2)) : 0
readonly property real bottomMargin: isVerticalOrientation ? (isBottomBarEdge && isLast ? barEdgeExtension : (isLast ? gapExtension : gapExtension / 2)) : 0
readonly property bool barUsesOverlayLayer: {
switch (Quickshell.env("DMS_DANKBAR_LAYER")) {
case "overlay":
return true;
case "bottom":
case "background":
case "top":
return false;
default:
return (barConfig?.useOverlayLayer ?? false) || CompositorService.framePeerSurfacesUseOverlayForScreen(parentScreen);
}
}
readonly property bool barUsesOverlayLayer: LayerShell.envUsesOverlay("DMS_DANKBAR_LAYER", (barConfig?.useOverlayLayer ?? false) || CompositorService.framePeerSurfacesUseOverlayForScreen(parentScreen))
signal clicked
signal rightClicked(real rootX, real rootY)