From 920353370bba555010506a1c0b204675c60362fe Mon Sep 17 00:00:00 2001 From: Vaxry <43317083+vaxerski@users.noreply.github.com> Date: Mon, 8 Dec 2025 15:04:40 +0000 Subject: desktop: cleanup, unify desktop elements as views (#12563) --- src/managers/SessionLockManager.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/managers/SessionLockManager.cpp') diff --git a/src/managers/SessionLockManager.cpp b/src/managers/SessionLockManager.cpp index f460e17e..1b0ec0bd 100644 --- a/src/managers/SessionLockManager.cpp +++ b/src/managers/SessionLockManager.cpp @@ -5,6 +5,7 @@ #include "../protocols/SessionLock.hpp" #include "../render/Renderer.hpp" #include "../desktop/state/FocusState.hpp" +#include "../desktop/view/SessionLock.hpp" #include "./managers/SeatManager.hpp" #include "./managers/input/InputManager.hpp" #include "./managers/eventLoop/EventLoopManager.hpp" @@ -68,9 +69,11 @@ void CSessionLockManager::onNewSessionLock(SP pLock) { m_sessionLock->listeners.newSurface = pLock->m_events.newLockSurface.listen([this](const SP& surface) { const auto PMONITOR = surface->monitor(); - const auto NEWSURFACE = m_sessionLock->vSessionLockSurfaces.emplace_back(makeUnique(surface)).get(); + const auto NEWSURFACE = m_sessionLock->vSessionLockSurfaces.emplace_back(makeShared(surface)); NEWSURFACE->iMonitorID = PMONITOR->m_id; PROTO::fractional->sendScale(surface->surface(), PMONITOR->m_scale); + + g_pCompositor->m_otherViews.emplace_back(Desktop::View::CSessionLock::create(surface)); }); m_sessionLock->listeners.unlock = pLock->m_events.unlockAndDestroy.listen([this] { -- cgit v1.2.3