mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2026-08-02 03:28:28 -04:00
Feature/split move size hyprland windowrules (#2824)
* windowrules: add split move/size fields for Lua table syntax * windowrules: remove deprecated Move/Size fields, switch QML to split fields * fix: use resolved dms binary path in Proc.runCommand
This commit is contained in:
@@ -68,7 +68,7 @@ Item {
|
||||
const compositorArg = compositor === "mango" ? "mangowc" : compositor;
|
||||
|
||||
checkingInclude = true;
|
||||
Proc.runCommand("check-layout-include", ["dms", "config", "resolve-include", compositorArg, filename], (output, exitCode) => {
|
||||
Proc.runCommand("check-layout-include", [Proc.dmsBin, "config", "resolve-include", compositorArg, filename], (output, exitCode) => {
|
||||
checkingInclude = false;
|
||||
if (exitCode !== 0) {
|
||||
layoutIncludeStatus = {
|
||||
|
||||
@@ -1443,7 +1443,7 @@ Singleton {
|
||||
const compositorArg = (compositor === "mango") ? "mangowc" : compositor;
|
||||
|
||||
checkingInclude = true;
|
||||
Proc.runCommand("check-outputs-include", ["dms", "config", "resolve-include", compositorArg, filename], (output, exitCode) => {
|
||||
Proc.runCommand("check-outputs-include", [Proc.dmsBin, "config", "resolve-include", compositorArg, filename], (output, exitCode) => {
|
||||
checkingInclude = false;
|
||||
if (exitCode !== 0) {
|
||||
includeStatus = {
|
||||
|
||||
@@ -117,7 +117,7 @@ Item {
|
||||
const compositorArg = (compositor === "mango") ? "mangowc" : compositor;
|
||||
|
||||
checkingCursorInclude = true;
|
||||
Proc.runCommand("check-cursor-include", ["dms", "config", "resolve-include", compositorArg, filename], (output, exitCode) => {
|
||||
Proc.runCommand("check-cursor-include", [Proc.dmsBin, "config", "resolve-include", compositorArg, filename], (output, exitCode) => {
|
||||
checkingCursorInclude = false;
|
||||
if (exitCode !== 0) {
|
||||
cursorIncludeStatus = {
|
||||
@@ -238,7 +238,7 @@ Item {
|
||||
return;
|
||||
matugenPreviewRequestKey = requestKey;
|
||||
|
||||
Proc.runCommand("", ["dms", "matugen", "preview", "--source-color", sourceColor, "--contrast", contrast.toString()], (output, exitCode) => {
|
||||
Proc.runCommand("", [Proc.dmsBin, "matugen", "preview", "--source-color", sourceColor, "--contrast", contrast.toString()], (output, exitCode) => {
|
||||
if (requestKey !== themeColorsTab.matugenPreviewRequestKey)
|
||||
return;
|
||||
if (exitCode !== 0) {
|
||||
@@ -262,7 +262,7 @@ Item {
|
||||
DMSService.listInstalledThemes();
|
||||
if (PopoutService.pendingThemeInstall)
|
||||
Qt.callLater(() => showThemeBrowser());
|
||||
Proc.runCommand("template-check", ["dms", "matugen", "check"], (output, exitCode) => {
|
||||
Proc.runCommand("template-check", [Proc.dmsBin, "matugen", "check"], (output, exitCode) => {
|
||||
if (exitCode !== 0)
|
||||
return;
|
||||
try {
|
||||
|
||||
@@ -122,8 +122,10 @@ Item {
|
||||
"norounding": I18n.tr("No Round"),
|
||||
"pin": I18n.tr("Pin"),
|
||||
"opaque": I18n.tr("Opaque"),
|
||||
"size": I18n.tr("Size"),
|
||||
"move": I18n.tr("Move"),
|
||||
"sizeWidth": I18n.tr("W"),
|
||||
"sizeHeight": I18n.tr("H"),
|
||||
"moveX": I18n.tr("X"),
|
||||
"moveY": I18n.tr("Y"),
|
||||
"monitor": I18n.tr("Monitor"),
|
||||
"workspace": I18n.tr("Workspace"),
|
||||
"drawBorderWithBackground": I18n.tr("Border w/ Bg"),
|
||||
@@ -198,7 +200,7 @@ Item {
|
||||
}
|
||||
|
||||
checkingInclude = true;
|
||||
Proc.runCommand("load-windowrules", ["dms", "config", "windowrules", "list", compositor], (output, exitCode) => {
|
||||
Proc.runCommand("load-windowrules", [Proc.dmsBin, "config", "windowrules", "list", compositor], (output, exitCode) => {
|
||||
checkingInclude = false;
|
||||
if (exitCode !== 0) {
|
||||
windowRules = [];
|
||||
@@ -234,7 +236,7 @@ Item {
|
||||
if (compositor !== "niri" && compositor !== "hyprland" && compositor !== "mango")
|
||||
return;
|
||||
|
||||
Proc.runCommand("remove-windowrule", ["dms", "config", "windowrules", "remove", compositor, ruleId], (output, exitCode) => {
|
||||
Proc.runCommand("remove-windowrule", [Proc.dmsBin, "config", "windowrules", "remove", compositor, ruleId], (output, exitCode) => {
|
||||
if (exitCode === 0) {
|
||||
if (CompositorService.isMango)
|
||||
MangoService.reloadConfig();
|
||||
@@ -260,7 +262,7 @@ Item {
|
||||
const [moved] = ids.splice(fromIndex, 1);
|
||||
ids.splice(toIndex, 0, moved);
|
||||
|
||||
Proc.runCommand("reorder-windowrules", ["dms", "config", "windowrules", "reorder", compositor, JSON.stringify(ids)], (output, exitCode) => {
|
||||
Proc.runCommand("reorder-windowrules", [Proc.dmsBin, "config", "windowrules", "reorder", compositor, JSON.stringify(ids)], (output, exitCode) => {
|
||||
if (exitCode === 0) {
|
||||
if (CompositorService.isMango)
|
||||
MangoService.reloadConfig();
|
||||
|
||||
Reference in New Issue
Block a user