diff options
Diffstat (limited to 'src/helpers.rs')
-rw-r--r-- | src/helpers.rs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/helpers.rs b/src/helpers.rs index b7488dd..24c8cf2 100644 --- a/src/helpers.rs +++ b/src/helpers.rs @@ -47,3 +47,10 @@ pub fn toggle_floating(wm: &mut WM<'_>) { wm.clients.toggle_floating(&wm.conn, pos); } } + +/// Toggle fullscreen status for the currently focused window +pub fn toggle_fullscreen(wm: &mut WM<'_>) { + if let Some(pos) = wm.clients.focused_pos() { + wm.clients.toggle_fullscreen(&wm.conn, pos); + } +} |