mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2026-08-06 21:48:30 -04:00
window rules: fix gating of window-rules to supported compositors
This commit is contained in:
@@ -1793,8 +1793,8 @@ Item {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function open(): string {
|
function open(): string {
|
||||||
if (!CompositorService.isNiri)
|
if (!CompositorService.isNiri && !CompositorService.isHyprland && !CompositorService.isMango)
|
||||||
return "WINDOW_RULES_NIRI_ONLY";
|
return "WINDOW_RULES_UNSUPPORTED_COMPOSITOR";
|
||||||
root.windowRuleModalLoader.active = true;
|
root.windowRuleModalLoader.active = true;
|
||||||
if (root.windowRuleModalLoader.item) {
|
if (root.windowRuleModalLoader.item) {
|
||||||
root.windowRuleModalLoader.item.show(getFocusedWindow());
|
root.windowRuleModalLoader.item.show(getFocusedWindow());
|
||||||
@@ -1812,8 +1812,8 @@ Item {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function toggle(): string {
|
function toggle(): string {
|
||||||
if (!CompositorService.isNiri)
|
if (!CompositorService.isNiri && !CompositorService.isHyprland && !CompositorService.isMango)
|
||||||
return "WINDOW_RULES_NIRI_ONLY";
|
return "WINDOW_RULES_UNSUPPORTED_COMPOSITOR";
|
||||||
root.windowRuleModalLoader.active = true;
|
root.windowRuleModalLoader.active = true;
|
||||||
if (root.windowRuleModalLoader.item) {
|
if (root.windowRuleModalLoader.item) {
|
||||||
if (root.windowRuleModalLoader.item.visible) {
|
if (root.windowRuleModalLoader.item.visible) {
|
||||||
|
|||||||
Reference in New Issue
Block a user