mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2026-04-09 23:32:10 -04:00
miraclewm: add support for Miracle WM
This commit is contained in:
@@ -96,7 +96,7 @@ Item {
|
||||
focusedScreenName = Hyprland.focusedWorkspace.monitor.name;
|
||||
} else if (CompositorService.isNiri && NiriService.currentOutput) {
|
||||
focusedScreenName = NiriService.currentOutput;
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll) {
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle) {
|
||||
const focusedWs = I3.workspaces?.values?.find(ws => ws.focused === true);
|
||||
focusedScreenName = focusedWs?.monitor?.name || "";
|
||||
} else if (CompositorService.isDwl && DwlService.activeOutput) {
|
||||
@@ -125,7 +125,7 @@ Item {
|
||||
focusedScreenName = Hyprland.focusedWorkspace.monitor.name;
|
||||
} else if (CompositorService.isNiri && NiriService.currentOutput) {
|
||||
focusedScreenName = NiriService.currentOutput;
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll) {
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle) {
|
||||
const focusedWs = I3.workspaces?.values?.find(ws => ws.focused === true);
|
||||
focusedScreenName = focusedWs?.monitor?.name || "";
|
||||
} else if (CompositorService.isDwl && DwlService.activeOutput) {
|
||||
|
||||
@@ -103,7 +103,7 @@ Item {
|
||||
}, (_, i) => i);
|
||||
}
|
||||
return DwlService.getVisibleTags(barWindow.screenName);
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll) {
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle) {
|
||||
const workspaces = I3.workspaces?.values || [];
|
||||
if (workspaces.length === 0)
|
||||
return [
|
||||
@@ -145,7 +145,7 @@ Item {
|
||||
return 0;
|
||||
const activeTags = DwlService.getActiveTags(barWindow.screenName);
|
||||
return activeTags.length > 0 ? activeTags[0] : 0;
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll) {
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle) {
|
||||
if (!barWindow.screenName || SettingsData.workspaceFollowFocus) {
|
||||
const focusedWs = I3.workspaces?.values?.find(ws => ws.focused === true);
|
||||
return focusedWs ? focusedWs.num : 1;
|
||||
@@ -194,7 +194,7 @@ Item {
|
||||
if (nextIndex !== validIndex) {
|
||||
DwlService.switchToTag(barWindow.screenName, realWorkspaces[nextIndex]);
|
||||
}
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll) {
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle) {
|
||||
const currentWs = getCurrentWorkspace();
|
||||
const currentIndex = realWorkspaces.findIndex(ws => ws.num === currentWs);
|
||||
const validIndex = currentIndex === -1 ? 0 : currentIndex;
|
||||
|
||||
@@ -55,7 +55,7 @@ BasePill {
|
||||
}
|
||||
|
||||
IconImage {
|
||||
visible: SettingsData.launcherLogoMode === "compositor" && (CompositorService.isNiri || CompositorService.isHyprland || CompositorService.isDwl || CompositorService.isSway || CompositorService.isScroll || CompositorService.isLabwc)
|
||||
visible: SettingsData.launcherLogoMode === "compositor" && (CompositorService.isNiri || CompositorService.isHyprland || CompositorService.isDwl || CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle || CompositorService.isLabwc)
|
||||
anchors.centerIn: parent
|
||||
width: Theme.barIconSize(root.barThickness, SettingsData.launcherLogoSizeOffset, root.barConfig?.noBackground)
|
||||
height: Theme.barIconSize(root.barThickness, SettingsData.launcherLogoSizeOffset, root.barConfig?.noBackground)
|
||||
@@ -72,6 +72,8 @@ BasePill {
|
||||
return "file://" + Theme.shellDir + "/assets/sway.svg";
|
||||
} else if (CompositorService.isScroll) {
|
||||
return "file://" + Theme.shellDir + "/assets/sway.svg";
|
||||
} else if (CompositorService.isMiracle) {
|
||||
return "file://" + Theme.shellDir + "/assets/miraclewm.svg";
|
||||
} else if (CompositorService.isLabwc) {
|
||||
return "file://" + Theme.shellDir + "/assets/labwc.png";
|
||||
}
|
||||
|
||||
@@ -37,6 +37,7 @@ Item {
|
||||
return DwlService.activeOutput || root.screenName;
|
||||
case "sway":
|
||||
case "scroll":
|
||||
case "miracle":
|
||||
const focusedWs = I3.workspaces?.values?.find(ws => ws.focused === true);
|
||||
return focusedWs?.monitor?.name || root.screenName;
|
||||
default:
|
||||
@@ -44,7 +45,7 @@ Item {
|
||||
}
|
||||
}
|
||||
|
||||
readonly property bool useExtWorkspace: DMSService.forceExtWorkspace || (!CompositorService.isNiri && !CompositorService.isHyprland && !CompositorService.isDwl && !CompositorService.isSway && !CompositorService.isScroll && ExtWorkspaceService.extWorkspaceAvailable)
|
||||
readonly property bool useExtWorkspace: DMSService.forceExtWorkspace || (!CompositorService.isNiri && !CompositorService.isHyprland && !CompositorService.isDwl && !CompositorService.isSway && !CompositorService.isScroll && !CompositorService.isMiracle && ExtWorkspaceService.extWorkspaceAvailable)
|
||||
|
||||
Connections {
|
||||
target: DesktopEntries
|
||||
@@ -67,6 +68,7 @@ Item {
|
||||
return activeTags.length > 0 ? activeTags[0] : -1;
|
||||
case "sway":
|
||||
case "scroll":
|
||||
case "miracle":
|
||||
return getSwayActiveWorkspace();
|
||||
default:
|
||||
return 1;
|
||||
@@ -97,6 +99,7 @@ Item {
|
||||
break;
|
||||
case "sway":
|
||||
case "scroll":
|
||||
case "miracle":
|
||||
baseList = getSwayWorkspaces();
|
||||
break;
|
||||
default:
|
||||
@@ -114,12 +117,23 @@ Item {
|
||||
}
|
||||
];
|
||||
|
||||
function mapWorkspace(ws) {
|
||||
return {
|
||||
"num": ws.number,
|
||||
"name": ws.name,
|
||||
"focused": ws.focused,
|
||||
"active": ws.active,
|
||||
"urgent": ws.urgent,
|
||||
"monitor": ws.monitor
|
||||
};
|
||||
}
|
||||
|
||||
if (!root.screenName || SettingsData.workspaceFollowFocus) {
|
||||
return workspaces.slice().sort((a, b) => a.num - b.num);
|
||||
return workspaces.slice().sort((a, b) => a.num - b.num).map(mapWorkspace);
|
||||
}
|
||||
|
||||
const monitorWorkspaces = workspaces.filter(ws => ws.monitor?.name === root.screenName);
|
||||
return monitorWorkspaces.length > 0 ? monitorWorkspaces.sort((a, b) => a.num - b.num) : [
|
||||
return monitorWorkspaces.length > 0 ? monitorWorkspaces.sort((a, b) => a.num - b.num).map(mapWorkspace) : [
|
||||
{
|
||||
"num": 1
|
||||
}
|
||||
@@ -222,7 +236,7 @@ Item {
|
||||
return [];
|
||||
}
|
||||
targetWorkspaceId = ws.tag;
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll) {
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle) {
|
||||
targetWorkspaceId = ws.num !== undefined ? ws.num : ws;
|
||||
} else {
|
||||
return [];
|
||||
@@ -234,7 +248,7 @@ Item {
|
||||
let isActiveWs = false;
|
||||
if (CompositorService.isNiri) {
|
||||
isActiveWs = NiriService.allWorkspaces.some(ws => ws.id === targetWorkspaceId && ws.is_active);
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll) {
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle) {
|
||||
const focusedWs = I3.workspaces?.values?.find(ws => ws.focused === true);
|
||||
isActiveWs = focusedWs ? (focusedWs.num === targetWorkspaceId) : false;
|
||||
} else if (CompositorService.isDwl) {
|
||||
@@ -255,7 +269,7 @@ Item {
|
||||
let winWs = null;
|
||||
if (CompositorService.isNiri) {
|
||||
winWs = w.workspace_id;
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll) {
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle) {
|
||||
winWs = w.workspace?.num;
|
||||
} else {
|
||||
const hyprlandToplevels = Array.from(Hyprland.toplevels?.values || []);
|
||||
@@ -322,7 +336,7 @@ Item {
|
||||
placeholder = {
|
||||
"tag": -1
|
||||
};
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll) {
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle) {
|
||||
placeholder = {
|
||||
"num": -1
|
||||
};
|
||||
@@ -516,7 +530,7 @@ Item {
|
||||
return ws && ws.id !== -1;
|
||||
if (CompositorService.isDwl)
|
||||
return ws && ws.tag !== -1;
|
||||
if (CompositorService.isSway || CompositorService.isScroll)
|
||||
if (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle)
|
||||
return ws && ws.num !== -1;
|
||||
return ws !== -1;
|
||||
});
|
||||
@@ -588,7 +602,7 @@ Item {
|
||||
}
|
||||
|
||||
DwlService.switchToTag(root.screenName, realWorkspaces[nextIndex].tag);
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll) {
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle) {
|
||||
const realWorkspaces = getRealWorkspaces();
|
||||
if (realWorkspaces.length < 2) {
|
||||
return;
|
||||
@@ -617,7 +631,7 @@ Item {
|
||||
return modelData?.id || "";
|
||||
if (CompositorService.isDwl)
|
||||
return (modelData?.tag !== undefined) ? (modelData.tag + 1) : "";
|
||||
if (CompositorService.isSway || CompositorService.isScroll)
|
||||
if (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle)
|
||||
return modelData?.num || "";
|
||||
return modelData - 1;
|
||||
}
|
||||
@@ -632,7 +646,7 @@ Item {
|
||||
isPlaceholder = modelData?.id === -1;
|
||||
} else if (CompositorService.isDwl) {
|
||||
isPlaceholder = modelData?.tag === -1;
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll) {
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle) {
|
||||
isPlaceholder = modelData?.num === -1;
|
||||
} else {
|
||||
isPlaceholder = modelData === -1;
|
||||
@@ -665,7 +679,7 @@ Item {
|
||||
return getWorkspaceIndexFallback(modelData, index);
|
||||
}
|
||||
|
||||
readonly property bool hasNativeWorkspaceSupport: CompositorService.isNiri || CompositorService.isHyprland || CompositorService.isDwl || CompositorService.isSway || CompositorService.isScroll
|
||||
readonly property bool hasNativeWorkspaceSupport: CompositorService.isNiri || CompositorService.isHyprland || CompositorService.isDwl || CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle
|
||||
readonly property bool hasWorkspaces: getRealWorkspaces().length > 0
|
||||
readonly property bool shouldShow: hasNativeWorkspaceSupport || (useExtWorkspace && hasWorkspaces)
|
||||
|
||||
@@ -865,7 +879,7 @@ Item {
|
||||
return !!(modelData && modelData.id === root.currentWorkspace);
|
||||
if (CompositorService.isDwl)
|
||||
return !!(modelData && root.dwlActiveTags.includes(modelData.tag));
|
||||
if (CompositorService.isSway || CompositorService.isScroll)
|
||||
if (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle)
|
||||
return !!(modelData && modelData.num === root.currentWorkspace);
|
||||
return modelData === root.currentWorkspace;
|
||||
}
|
||||
@@ -889,7 +903,7 @@ Item {
|
||||
return !!(modelData && modelData.id === -1);
|
||||
if (CompositorService.isDwl)
|
||||
return !!(modelData && modelData.tag === -1);
|
||||
if (CompositorService.isSway || CompositorService.isScroll)
|
||||
if (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle)
|
||||
return !!(modelData && modelData.num === -1);
|
||||
return modelData === -1;
|
||||
}
|
||||
@@ -906,7 +920,7 @@ Item {
|
||||
return loadedIsUrgent;
|
||||
if (CompositorService.isDwl)
|
||||
return modelData?.state === 2;
|
||||
if (CompositorService.isSway || CompositorService.isScroll)
|
||||
if (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle)
|
||||
return loadedIsUrgent;
|
||||
return false;
|
||||
}
|
||||
@@ -927,7 +941,7 @@ Item {
|
||||
targetWorkspaceId = modelData?.id;
|
||||
} else if (CompositorService.isDwl) {
|
||||
targetWorkspaceId = modelData?.tag;
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll) {
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle) {
|
||||
targetWorkspaceId = modelData?.num;
|
||||
}
|
||||
if (targetWorkspaceId === undefined || targetWorkspaceId === null)
|
||||
@@ -946,7 +960,7 @@ Item {
|
||||
let winWs = null;
|
||||
if (CompositorService.isNiri) {
|
||||
winWs = w.workspace_id;
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll) {
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle) {
|
||||
winWs = w.workspace?.num;
|
||||
} else if (CompositorService.isHyprland) {
|
||||
const hyprlandToplevels = Array.from(Hyprland.toplevels?.values || []);
|
||||
@@ -971,7 +985,7 @@ Item {
|
||||
readonly property real baseWidth: root.isVertical ? (SettingsData.showWorkspaceApps ? Math.max(widgetHeight * 0.7, root.appIconSize + Theme.spacingXS * 2) : widgetHeight * 0.5) : (isActive ? root.widgetHeight * 1.05 : root.widgetHeight * 0.7)
|
||||
readonly property real baseHeight: root.isVertical ? (isActive ? root.widgetHeight * 1.05 : root.widgetHeight * 0.7) : (SettingsData.showWorkspaceApps ? Math.max(widgetHeight * 0.7, root.appIconSize + Theme.spacingXS * 2) : widgetHeight * 0.5)
|
||||
readonly property bool hasWorkspaceName: SettingsData.showWorkspaceName && modelData?.name && modelData.name !== ""
|
||||
readonly property bool workspaceNamesEnabled: SettingsData.showWorkspaceName && CompositorService.isNiri
|
||||
readonly property bool workspaceNamesEnabled: SettingsData.showWorkspaceName && (CompositorService.isNiri || CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle)
|
||||
readonly property real contentImplicitWidth: (hasWorkspaceName || loadedHasIcon) ? (appIconsLoader.item?.contentWidth ?? 0) : 0
|
||||
readonly property real contentImplicitHeight: (workspaceNamesEnabled || loadedHasIcon) ? (appIconsLoader.item?.contentHeight ?? 0) : 0
|
||||
|
||||
@@ -1123,9 +1137,7 @@ Item {
|
||||
return;
|
||||
|
||||
if (!dragHandler.dragging) {
|
||||
const distance = root.isVertical
|
||||
? Math.abs(mouse.y - dragHandler.dragStartPos.y)
|
||||
: Math.abs(mouse.x - dragHandler.dragStartPos.x);
|
||||
const distance = root.isVertical ? Math.abs(mouse.y - dragHandler.dragStartPos.y) : Math.abs(mouse.x - dragHandler.dragStartPos.x);
|
||||
if (distance > 5) {
|
||||
dragHandler.dragging = true;
|
||||
root.dragSourceIndex = index;
|
||||
@@ -1136,9 +1148,7 @@ Item {
|
||||
if (!dragHandler.dragging)
|
||||
return;
|
||||
|
||||
const rawAxisOffset = root.isVertical
|
||||
? (mouse.y - dragHandler.dragStartPos.y)
|
||||
: (mouse.x - dragHandler.dragStartPos.x);
|
||||
const rawAxisOffset = root.isVertical ? (mouse.y - dragHandler.dragStartPos.y) : (mouse.x - dragHandler.dragStartPos.x);
|
||||
|
||||
const itemSize = (root.isVertical ? delegateRoot.height : delegateRoot.width) + Theme.spacingS;
|
||||
const maxOffsetPositive = (root.workspaceList.length - 1 - index) * itemSize;
|
||||
@@ -1189,7 +1199,7 @@ Item {
|
||||
Hyprland.dispatch(`workspace ${modelData.id}`);
|
||||
} else if (CompositorService.isDwl && modelData?.tag !== undefined) {
|
||||
DwlService.switchToTag(root.screenName, modelData.tag);
|
||||
} else if ((CompositorService.isSway || CompositorService.isScroll) && modelData?.num) {
|
||||
} else if ((CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle) && modelData?.num) {
|
||||
try {
|
||||
I3.dispatch(`workspace number ${modelData.num}`);
|
||||
} catch (_) {}
|
||||
@@ -1228,7 +1238,7 @@ Item {
|
||||
wsData = modelData;
|
||||
} else if (CompositorService.isDwl) {
|
||||
wsData = modelData;
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll) {
|
||||
} else if (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle) {
|
||||
wsData = modelData;
|
||||
}
|
||||
delegateRoot.loadedWorkspaceData = wsData;
|
||||
@@ -1247,7 +1257,7 @@ Item {
|
||||
delegateRoot.loadedHasIcon = icData !== null;
|
||||
|
||||
if (SettingsData.showWorkspaceApps) {
|
||||
if (CompositorService.isDwl || CompositorService.isSway || CompositorService.isScroll) {
|
||||
if (CompositorService.isDwl || CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle) {
|
||||
delegateRoot.loadedIcons = root.getWorkspaceIcons(modelData);
|
||||
} else if (CompositorService.isNiri) {
|
||||
delegateRoot.loadedIcons = root.getWorkspaceIcons(isPlaceholder ? null : modelData);
|
||||
@@ -1760,7 +1770,7 @@ Item {
|
||||
}
|
||||
Connections {
|
||||
target: I3.workspaces
|
||||
enabled: (CompositorService.isSway || CompositorService.isScroll)
|
||||
enabled: (CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle)
|
||||
function onValuesChanged() {
|
||||
delegateRoot.updateAllData();
|
||||
}
|
||||
|
||||
@@ -74,6 +74,8 @@ Card {
|
||||
return "on Sway";
|
||||
if (CompositorService.isScroll)
|
||||
return "on Scroll";
|
||||
if (CompositorService.isMiracle)
|
||||
return "on Miracle WM";
|
||||
return "";
|
||||
}
|
||||
font.pixelSize: Theme.fontSizeSmall
|
||||
|
||||
@@ -236,7 +236,7 @@ Item {
|
||||
}
|
||||
|
||||
IconImage {
|
||||
visible: SettingsData.dockLauncherLogoMode === "compositor" && (CompositorService.isNiri || CompositorService.isHyprland || CompositorService.isDwl || CompositorService.isSway || CompositorService.isScroll || CompositorService.isLabwc)
|
||||
visible: SettingsData.dockLauncherLogoMode === "compositor" && (CompositorService.isNiri || CompositorService.isHyprland || CompositorService.isDwl || CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle || CompositorService.isLabwc)
|
||||
anchors.centerIn: parent
|
||||
width: actualIconSize + SettingsData.dockLauncherLogoSizeOffset
|
||||
height: actualIconSize + SettingsData.dockLauncherLogoSizeOffset
|
||||
@@ -253,6 +253,8 @@ Item {
|
||||
return "file://" + Theme.shellDir + "/assets/sway.svg";
|
||||
} else if (CompositorService.isScroll) {
|
||||
return "file://" + Theme.shellDir + "/assets/sway.svg";
|
||||
} else if (CompositorService.isMiracle) {
|
||||
return "file://" + Theme.shellDir + "/assets/miraclewm.svg";
|
||||
} else if (CompositorService.isLabwc) {
|
||||
return "file://" + Theme.shellDir + "/assets/labwc.png";
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@ dms-greeter - DankMaterialShell greeter launcher
|
||||
Usage: dms-greeter --command COMPOSITOR [OPTIONS]
|
||||
|
||||
Required:
|
||||
--command COMPOSITOR Compositor to use (niri, hyprland, sway, scroll, mango, or labwc)
|
||||
--command COMPOSITOR Compositor to use (niri, hyprland, sway, scroll, miracle, mango, or labwc)
|
||||
|
||||
Options:
|
||||
-C, --config PATH Custom compositor config file
|
||||
@@ -244,6 +244,24 @@ SCROLL_EOF
|
||||
exec scroll -c "$COMPOSITOR_CONFIG"
|
||||
;;
|
||||
|
||||
miracle|miracle-wm)
|
||||
if [[ -z "$COMPOSITOR_CONFIG" ]]; then
|
||||
TEMP_CONFIG=$(mktemp)
|
||||
cat > "$TEMP_CONFIG" << MIRACLE_EOF
|
||||
exec "$QS_CMD; miraclemsg exit"
|
||||
MIRACLE_EOF
|
||||
COMPOSITOR_CONFIG="$TEMP_CONFIG"
|
||||
else
|
||||
TEMP_CONFIG=$(mktemp)
|
||||
cat "$COMPOSITOR_CONFIG" > "$TEMP_CONFIG"
|
||||
cat >> "$TEMP_CONFIG" << MIRACLE_EOF
|
||||
|
||||
exec "$QS_CMD; miraclemsg exit"
|
||||
MIRACLE_EOF
|
||||
COMPOSITOR_CONFIG="$TEMP_CONFIG"
|
||||
fi
|
||||
exec miracle-wm -c "$COMPOSITOR_CONFIG"
|
||||
;;
|
||||
|
||||
labwc)
|
||||
if [[ -n "$COMPOSITOR_CONFIG" ]]; then
|
||||
@@ -263,7 +281,7 @@ SCROLL_EOF
|
||||
|
||||
*)
|
||||
echo "Error: Unsupported compositor: $COMPOSITOR" >&2
|
||||
echo "Supported compositors: niri, hyprland, sway, scroll, mango, labwc" >&2
|
||||
echo "Supported compositors: niri, hyprland, sway, scroll, miracle, mango, labwc" >&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
@@ -14,6 +14,7 @@ Item {
|
||||
property bool isNiri: CompositorService.isNiri
|
||||
property bool isSway: CompositorService.isSway
|
||||
property bool isScroll: CompositorService.isScroll
|
||||
property bool isMiracle: CompositorService.isMiracle
|
||||
property bool isDwl: CompositorService.isDwl
|
||||
property bool isLabwc: CompositorService.isLabwc
|
||||
|
||||
@@ -24,6 +25,8 @@ Item {
|
||||
return "sway";
|
||||
if (isScroll)
|
||||
return "scroll";
|
||||
if (isMiracle)
|
||||
return "miracle";
|
||||
if (isDwl)
|
||||
return "mangowc";
|
||||
if (isLabwc)
|
||||
@@ -38,6 +41,8 @@ Item {
|
||||
return "/assets/sway.svg";
|
||||
if (isScroll)
|
||||
return "/assets/sway.svg";
|
||||
if (isMiracle)
|
||||
return "/assets/miraclewm.svg";
|
||||
if (isDwl)
|
||||
return "/assets/mango.png";
|
||||
if (isLabwc)
|
||||
@@ -52,6 +57,8 @@ Item {
|
||||
return "https://swaywm.org";
|
||||
if (isScroll)
|
||||
return "https://github.com/dawsers/scroll";
|
||||
if (isMiracle)
|
||||
return "https://github.com/miracle-wm-org/miracle-wm";
|
||||
if (isDwl)
|
||||
return "https://github.com/DreamMaoMao/mangowc";
|
||||
if (isLabwc)
|
||||
@@ -66,6 +73,8 @@ Item {
|
||||
return "Sway Website";
|
||||
if (isScroll)
|
||||
return "Scroll Github";
|
||||
if (isMiracle)
|
||||
return "Miracle WM GitHub";
|
||||
if (isDwl)
|
||||
return "mangowc GitHub";
|
||||
if (isLabwc)
|
||||
@@ -98,9 +107,9 @@ Item {
|
||||
property string ircUrl: "https://web.libera.chat/gamja/?channels=#labwc"
|
||||
property string ircTooltip: "LabWC IRC Channel"
|
||||
|
||||
property bool showMatrix: isNiri && !isHyprland && !isSway && !isScroll && !isDwl && !isLabwc
|
||||
property bool showMatrix: isNiri && !isHyprland && !isSway && !isScroll && !isMiracle && !isDwl && !isLabwc
|
||||
property bool showCompositorDiscord: isHyprland || isDwl
|
||||
property bool showReddit: isNiri && !isHyprland && !isSway && !isScroll && !isDwl && !isLabwc
|
||||
property bool showReddit: isNiri && !isHyprland && !isSway && !isScroll && !isMiracle && !isDwl && !isLabwc
|
||||
property bool showIrc: isLabwc
|
||||
|
||||
DankFlickable {
|
||||
|
||||
@@ -264,6 +264,8 @@ Item {
|
||||
modes.push("Sway");
|
||||
} else if (CompositorService.isScroll) {
|
||||
modes.push("Scroll");
|
||||
} else if (CompositorService.isMiracle) {
|
||||
modes.push("Miracle");
|
||||
} else {
|
||||
modes.push(I18n.tr("Compositor"));
|
||||
}
|
||||
|
||||
@@ -67,6 +67,8 @@ Item {
|
||||
modes.push("Sway");
|
||||
} else if (CompositorService.isScroll) {
|
||||
modes.push("Scroll");
|
||||
} else if (CompositorService.isMiracle) {
|
||||
modes.push("Miracle");
|
||||
} else {
|
||||
modes.push(I18n.tr("Compositor"));
|
||||
}
|
||||
|
||||
@@ -131,7 +131,7 @@ Item {
|
||||
text: I18n.tr("Follow Monitor Focus")
|
||||
description: I18n.tr("Show workspaces of the currently focused monitor")
|
||||
checked: SettingsData.workspaceFollowFocus
|
||||
visible: CompositorService.isNiri || CompositorService.isHyprland || CompositorService.isDwl || CompositorService.isSway || CompositorService.isScroll
|
||||
visible: CompositorService.isNiri || CompositorService.isHyprland || CompositorService.isDwl || CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle
|
||||
onToggled: checked => SettingsData.set("workspaceFollowFocus", checked)
|
||||
}
|
||||
|
||||
@@ -296,12 +296,12 @@ Item {
|
||||
height: 1
|
||||
color: Theme.outline
|
||||
opacity: 0.15
|
||||
visible: CompositorService.isNiri || CompositorService.isHyprland || CompositorService.isDwl || CompositorService.isSway || CompositorService.isScroll
|
||||
visible: CompositorService.isNiri || CompositorService.isHyprland || CompositorService.isDwl || CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle
|
||||
}
|
||||
|
||||
SettingsButtonGroupRow {
|
||||
text: I18n.tr("Urgent Color")
|
||||
visible: CompositorService.isNiri || CompositorService.isHyprland || CompositorService.isDwl || CompositorService.isSway || CompositorService.isScroll
|
||||
visible: CompositorService.isNiri || CompositorService.isHyprland || CompositorService.isDwl || CompositorService.isSway || CompositorService.isScroll || CompositorService.isMiracle
|
||||
model: ["err", "pri", "sec", "s", "sc"]
|
||||
buttonHeight: 22
|
||||
minButtonWidth: 36
|
||||
|
||||
Reference in New Issue
Block a user