toggles: fix sysmon + not toggling ws

This commit is contained in:
2 * r + 2 * t
2025-06-11 20:42:33 +10:00
parent d44bde1667
commit 3fa4a5f7b7
+4 -1
View File
@@ -50,6 +50,7 @@ class Command:
def communication(self) -> None: def communication(self) -> None:
self.spawn_or_move(lambda c: c["class"] == "discord", ["discord"], "communication") self.spawn_or_move(lambda c: c["class"] == "discord", ["discord"], "communication")
self.move_client(lambda c: c["class"] == "whatsapp", "communication") self.move_client(lambda c: c["class"] == "whatsapp", "communication")
hypr.dispatch("togglespecialworkspace", "communication")
def music(self) -> None: def music(self) -> None:
self.spawn_or_move( self.spawn_or_move(
@@ -58,16 +59,18 @@ class Command:
"music", "music",
) )
self.move_client(lambda c: c["class"] == "feishin", "music") self.move_client(lambda c: c["class"] == "feishin", "music")
hypr.dispatch("togglespecialworkspace", "music")
def sysmon(self) -> None: def sysmon(self) -> None:
self.spawn_client( self.spawn_client(
lambda c: c["class"] == "btop" and c["title"] == "btop" and c["workspace"]["name"] == "special:sysmon", lambda c: c["class"] == "btop" and c["title"] == "btop" and c["workspace"]["name"] == "special:sysmon",
["foot", "-a", "btop", "-T", "btop", "--", "btop"], ["foot", "-a", "btop", "-T", "btop", "--", "btop"],
"sysmon",
) )
hypr.dispatch("togglespecialworkspace", "sysmon")
def todo(self) -> None: def todo(self) -> None:
self.spawn_or_move(lambda c: c["class"] == "Todoist", ["todoist"], "todo") self.spawn_or_move(lambda c: c["class"] == "Todoist", ["todoist"], "todo")
hypr.dispatch("togglespecialworkspace", "todo")
def specialws(self) -> None: def specialws(self) -> None:
workspaces = hypr.message("workspaces") workspaces = hypr.message("workspaces")