diff options
Diffstat (limited to 'src/managers/SessionLockManager.hpp')
| -rw-r--r-- | src/managers/SessionLockManager.hpp | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/managers/SessionLockManager.hpp b/src/managers/SessionLockManager.hpp index da15496e..2938a851 100644 --- a/src/managers/SessionLockManager.hpp +++ b/src/managers/SessionLockManager.hpp @@ -3,6 +3,7 @@ #include "../defines.hpp" #include "../helpers/time/Timer.hpp" #include "../helpers/signal/Signal.hpp" +#include "./eventLoop/EventLoopTimer.hpp" #include <cstdint> #include <unordered_map> #include <unordered_set> @@ -29,10 +30,10 @@ struct SSessionLockSurface { struct SSessionLock { WP<CSessionLock> lock; - CTimer mLockTimer; + CTimer lockTimer; + SP<CEventLoopTimer> sendDeniedTimer; std::vector<UP<SSessionLockSurface>> vSessionLockSurfaces; - std::unordered_map<uint64_t, CTimer> mMonitorsWithoutMappedSurfaceTimers; struct { CHyprSignalListener newSurface; @@ -41,6 +42,7 @@ struct SSessionLock { } listeners; bool hasSentLocked = false; + bool hasSentDenied = false; std::unordered_set<uint64_t> lockedMonitors; }; @@ -51,10 +53,9 @@ class CSessionLockManager { WP<SSessionLockSurface> getSessionLockSurfaceForMonitor(uint64_t); - float getRedScreenAlphaForMonitor(uint64_t); - bool isSessionLocked(); - bool isSessionLockPresent(); + bool clientLocked(); + bool clientDenied(); bool isSurfaceSessionLock(SP<CWLSurfaceResource>); bool anySessionLockSurfacesPresent(); @@ -72,6 +73,7 @@ class CSessionLockManager { } m_listeners; void onNewSessionLock(SP<CSessionLock> pWlrLock); + void removeSendDeniedTimer(); }; inline UP<CSessionLockManager> g_pSessionLockManager; |
