diff options
| author | Peter Collingbourne <peter@pcc.me.uk> | 2024-06-09 21:09:28 -0700 |
|---|---|---|
| committer | Ivan Molodetskikh <yalterz@gmail.com> | 2024-06-10 18:06:34 +0300 |
| commit | bc3d6cac805bde6a26232dfa75c37b18ca9ec743 (patch) | |
| tree | 7c104f1d7da2c5727d4a6ffc812ffa81011e1864 /src/niri.rs | |
| parent | a55e385b12f27e3e700ae759d620b401f910288f (diff) | |
| download | niri-bc3d6cac805bde6a26232dfa75c37b18ca9ec743.tar.gz niri-bc3d6cac805bde6a26232dfa75c37b18ca9ec743.tar.bz2 niri-bc3d6cac805bde6a26232dfa75c37b18ca9ec743.zip | |
Implement xdg_activation_v1
Fixes #30.
Diffstat (limited to 'src/niri.rs')
| -rw-r--r-- | src/niri.rs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/niri.rs b/src/niri.rs index 7da671c2..c03edd19 100644 --- a/src/niri.rs +++ b/src/niri.rs @@ -90,6 +90,7 @@ use smithay::wayland::tablet_manager::TabletManagerState; use smithay::wayland::text_input::TextInputManagerState; use smithay::wayland::viewporter::ViewporterState; use smithay::wayland::virtual_keyboard::VirtualKeyboardManagerState; +use smithay::wayland::xdg_activation::XdgActivationState; use smithay::wayland::xdg_foreign::XdgForeignState; use crate::backend::tty::SurfaceDmabufFeedback; @@ -217,6 +218,7 @@ pub struct Niri { pub presentation_state: PresentationState, pub security_context_state: SecurityContextState, pub gamma_control_manager_state: GammaControlManagerState, + pub activation_state: XdgActivationState, pub seat: Seat<State>, /// Scancodes of the keys to suppress. @@ -1369,6 +1371,7 @@ impl Niri { GammaControlManagerState::new::<State, _>(&display_handle, move |client| { is_tty && !client.get_data::<ClientState>().unwrap().restricted }); + let activation_state = XdgActivationState::new::<State>(&display_handle); let mut seat: Seat<State> = seat_state.new_wl_seat(&display_handle, backend.seat_name()); seat.add_keyboard( @@ -1527,6 +1530,7 @@ impl Niri { presentation_state, security_context_state, gamma_control_manager_state, + activation_state, seat, keyboard_focus: KeyboardFocus::Layout { surface: None }, |
