forge
Explore
Log in

Don't you dare go Hollow

Unset the minimize capability

Browse files at this commit

64610d1e24770857edf99eb4254c0cb06abd8d08Ivan MolodetskikhParent: 9126c60
src/niri.rsmodified+9 -1
@@ -12,6 +12,7 @@ use smithay::input::{Seat, SeatState};
12 use smithay::output::Output;12 use smithay::output::Output;
13 use smithay::reexports::calloop::generic::Generic;13 use smithay::reexports::calloop::generic::Generic;
14 use smithay::reexports::calloop::{Interest, LoopHandle, LoopSignal, Mode, PostAction};14 use smithay::reexports::calloop::{Interest, LoopHandle, LoopSignal, Mode, PostAction};
15+use smithay::reexports::wayland_protocols::xdg::shell::server::xdg_toplevel::WmCapabilities;
15 use smithay::reexports::wayland_server::backend::{ClientData, ClientId, DisconnectReason};16 use smithay::reexports::wayland_server::backend::{ClientData, ClientId, DisconnectReason};
16 use smithay::reexports::wayland_server::protocol::wl_surface::WlSurface;17 use smithay::reexports::wayland_server::protocol::wl_surface::WlSurface;
17 use smithay::reexports::wayland_server::{Display, DisplayHandle};18 use smithay::reexports::wayland_server::{Display, DisplayHandle};
@@ -65,7 +66,14 @@ impl Niri {
65 let display_handle = display.handle();66 let display_handle = display.handle();
66 67
67 let compositor_state = CompositorState::new::<Self>(&display_handle);68 let compositor_state = CompositorState::new::<Self>(&display_handle);
68- let xdg_shell_state = XdgShellState::new::<Self>(&display_handle);69+ let xdg_shell_state = XdgShellState::new_with_capabilities::<Self>(
70+ &display_handle,
71+ [
72+ WmCapabilities::Fullscreen,
73+ WmCapabilities::Maximize,
74+ WmCapabilities::WindowMenu,
75+ ],
76+ );
69 let shm_state = ShmState::new::<Self>(&display_handle, vec![]);77 let shm_state = ShmState::new::<Self>(&display_handle, vec![]);
70 let output_manager_state = OutputManagerState::new_with_xdg_output::<Self>(&display_handle);78 let output_manager_state = OutputManagerState::new_with_xdg_output::<Self>(&display_handle);
71 let mut seat_state = SeatState::new();79 let mut seat_state = SeatState::new();