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/PointerConstraints.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/protocols/PointerConstraints.cpp') diff --git a/src/protocols/PointerConstraints.cpp b/src/protocols/PointerConstraints.cpp index 7b5729c0..87abdcdd 100644 --- a/src/protocols/PointerConstraints.cpp +++ b/src/protocols/PointerConstraints.cpp @@ -2,6 +2,7 @@ #include "../desktop/WLSurface.hpp" #include "../Compositor.hpp" #include "../config/ConfigValue.hpp" +#include "../managers/SeatManager.hpp" #define LOGM PROTO::constraints->protoLog @@ -125,10 +126,10 @@ void CPointerConstraint::activate() { return; // TODO: hack, probably not a super duper great idea - if (g_pCompositor->m_sSeat.seat->pointer_state.focused_surface != pHLSurface->wlr()) { + if (g_pSeatManager->state.pointerFocus != pHLSurface->wlr()) { const auto SURFBOX = pHLSurface->getSurfaceBoxGlobal(); const auto LOCAL = SURFBOX.has_value() ? logicPositionHint() - SURFBOX->pos() : Vector2D{}; - wlr_seat_pointer_enter(g_pCompositor->m_sSeat.seat, pHLSurface->wlr(), LOCAL.x, LOCAL.y); + g_pSeatManager->setPointerFocus(pHLSurface->wlr(), LOCAL); } if (locked) -- cgit v1.2.3