summaryrefslogtreecommitdiff
path: root/src/helpers.rs
diff options
context:
space:
mode:
authortcmal <me@aria.rip>2024-08-30 16:51:50 +0100
committertcmal <me@aria.rip>2024-08-30 17:10:47 +0100
commit8fc827a3b30de16b6adbf80abea3bc224d507268 (patch)
treec9a37a1dbaf02ec3b52000b5feaa3cba6af511ef /src/helpers.rs
parenta568b4a79d1ccabfdff0a5a8ecbb908e96f17cf5 (diff)
Add bind for going back and forth between tags
Diffstat (limited to 'src/helpers.rs')
-rw-r--r--src/helpers.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/helpers.rs b/src/helpers.rs
index cd9fd18..d882bbe 100644
--- a/src/helpers.rs
+++ b/src/helpers.rs
@@ -98,6 +98,12 @@ pub fn set_tag_focus(wm: &mut WM<'_>, tag_focus: TagFocus) {
.set_mon_tag_focus(&wm.conn, wm.clients.focused_mon_idx(), tag_focus);
}
+/// Set the focused tag for the currently selected monitor to the previous value
+pub fn prev_tag_focus(wm: &mut WM<'_>) {
+ wm.clients
+ .mon_prev_tag_focus(&wm.conn, wm.clients.focused_mon_idx());
+}
+
/// Set the tag for the currently selected client
pub fn set_tag(wm: &mut WM<'_>, tag: Tag) {
if let Some(pos) = wm.clients.focused_pos() {