From 55f6d54de27178e12d961be4eb74e855b588457e Mon Sep 17 00:00:00 2001 From: MrNavaStar Date: Fri, 17 Jan 2025 22:36:02 -0700 Subject: [PATCH] Enable smithay viewporter protocol This fixes issue #70 --- src/server/mod.rs | 3 +++ src/server/smithay_handlers.rs | 1 + 2 files changed, 4 insertions(+) diff --git a/src/server/mod.rs b/src/server/mod.rs index 04cb6f3a..2ae88339 100644 --- a/src/server/mod.rs +++ b/src/server/mod.rs @@ -39,6 +39,7 @@ use smithay::wayland::shell::kde::decoration::KdeDecorationState; use smithay::wayland::shell::xdg::XdgShellState; use smithay::wayland::shell::xdg::decoration::XdgDecorationState; use smithay::wayland::shm::ShmState; +use smithay::wayland::viewporter::ViewporterState; use smithay::reexports::wayland_protocols_misc::server_decoration::server::org_kde_kwin_server_decoration_manager::Mode as KdeDecorationMode; use crate::prelude::*; @@ -96,6 +97,7 @@ pub struct WprsServerState { pub seat_state: SeatState, pub data_device_state: DataDeviceState, pub primary_selection_state: PrimarySelectionState, + pub viewport_state: ViewporterState, pub seat: Seat, @@ -151,6 +153,7 @@ impl WprsServerState { seat_state, data_device_state: DataDeviceState::new::(&dh), primary_selection_state: PrimarySelectionState::new::(&dh), + viewport_state: ViewporterState::new::(&dh), seat, serializer, object_map: HashMap::new(), diff --git a/src/server/smithay_handlers.rs b/src/server/smithay_handlers.rs index c947d22d..aa3d76fd 100644 --- a/src/server/smithay_handlers.rs +++ b/src/server/smithay_handlers.rs @@ -1229,3 +1229,4 @@ smithay::delegate_seat!(WprsServerState); smithay::delegate_data_device!(WprsServerState); smithay::delegate_output!(WprsServerState); smithay::delegate_primary_selection!(WprsServerState); +smithay::delegate_viewporter!(WprsServerState);