summaryrefslogtreecommitdiff
path: root/src/clients
diff options
context:
space:
mode:
authortcmal <me@aria.rip>2024-08-30 15:12:09 +0100
committertcmal <me@aria.rip>2024-08-30 15:13:55 +0100
commite6d583df4243e18707dfabbf375b57d811f07bf3 (patch)
tree72eaa1aa19359aa57b98af7daed5dee728b8528f /src/clients
parentd2506fbbee01e26f8decd0ce2371e674086c4300 (diff)
Only change focus within current workspace with keyboard
Diffstat (limited to 'src/clients')
-rw-r--r--src/clients/mod.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/clients/mod.rs b/src/clients/mod.rs
index 6481c0f..da341ba 100644
--- a/src/clients/mod.rs
+++ b/src/clients/mod.rs
@@ -295,11 +295,13 @@ impl ClientState {
return;
}
+ let tag_focus = self.focused_mon().focused_tag;
let curr_focused = self.focused_client.unwrap_or(0);
let look_through = self
.clients
.iter()
.enumerate()
+ .filter(|(_, c)| tag_focus.matches(c.tag))
.filter(|(_, c)| self.focused_mon().screen_info.contains(c.x(), c.y()))
.map(|(i, _)| i);