From 121d3a72137d4780602cf245704615f63357ea22 Mon Sep 17 00:00:00 2001 From: Vaxry Date: Fri, 10 May 2024 18:27:57 +0100 Subject: wl_seat: move to hyprland impl --- src/protocols/RelativePointer.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'src/protocols/RelativePointer.cpp') diff --git a/src/protocols/RelativePointer.cpp b/src/protocols/RelativePointer.cpp index c64687ee..e4818758 100644 --- a/src/protocols/RelativePointer.cpp +++ b/src/protocols/RelativePointer.cpp @@ -1,5 +1,7 @@ #include "RelativePointer.hpp" -#include "Compositor.hpp" +#include "../Compositor.hpp" +#include "../managers/SeatManager.hpp" +#include "core/Seat.hpp" #include CRelativePointer::CRelativePointer(SP resource_) : resource(resource_) { @@ -58,10 +60,10 @@ void CRelativePointerProtocol::onGetRelativePointer(CZwpRelativePointerManagerV1 void CRelativePointerProtocol::sendRelativeMotion(uint64_t time, const Vector2D& delta, const Vector2D& deltaUnaccel) { - if (!g_pCompositor->m_sSeat.seat->pointer_state.focused_client) + if (!g_pSeatManager->state.pointerFocusResource) return; - const auto FOCUSED = g_pCompositor->m_sSeat.seat->pointer_state.focused_client->client; + const auto FOCUSED = g_pSeatManager->state.pointerFocusResource->client(); for (auto& rp : m_vRelativePointers) { if (FOCUSED != rp->client()) -- cgit v1.2.3