diff options
Diffstat (limited to 'crates/wayland/src/state/menu.rs')
| -rw-r--r-- | crates/wayland/src/state/menu.rs | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/crates/wayland/src/state/menu.rs b/crates/wayland/src/state/menu.rs index 9f645a8..b8cf094 100644 --- a/crates/wayland/src/state/menu.rs +++ b/crates/wayland/src/state/menu.rs @@ -45,14 +45,32 @@ impl CompState { self.sync_geometry(window); foreign_toplevel::send_state(self, window); } + MenuAction::ToggleFullscreen => { + self.wm.borrow_mut().toggle_fullscreen(window); + self.sync_geometry(window); + foreign_toplevel::send_state(self, window); + } + MenuAction::ToggleFloating => { + self.wm.borrow_mut().toggle_floating(window); + self.sync_geometry(window); + } MenuAction::ToggleAlwaysOnTop => { self.wm.borrow_mut().toggle_always_on_top(window); } + MenuAction::MoveToWorkspace(workspace) => { + self.wm.borrow_mut().move_window_to_workspace(window, workspace); + } MenuAction::Close => { if let Some(w) = self.id_to_window.get(&window) { crate::input::close_dwindow(w); } } + // Never actually reached: the click-dispatch site + // (`input/pointer.rs`) intercepts `Separator` before calling + // this function at all. Handled here too so this match stays + // exhaustive without a catch-all that would silently swallow a + // real future variant added without updating this function. + MenuAction::Separator => {} } } |