diff options
| author | davc0n <dconti.dev@gmail.com> | 2025-05-01 23:57:11 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-05-01 23:57:11 +0200 |
| commit | 5b3e489108d8512fb5dfacf07b2aa3a71208e0f0 (patch) | |
| tree | 658b5136c8994731d858eeaedc7a09518c86e010 /src/managers/input/IdleInhibitor.cpp | |
| parent | 2670b8f7724e94020f21fe81483e69d73e1337cf (diff) | |
inputs: refactor class member vars (#10230)
Diffstat (limited to 'src/managers/input/IdleInhibitor.cpp')
| -rw-r--r-- | src/managers/input/IdleInhibitor.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/managers/input/IdleInhibitor.cpp b/src/managers/input/IdleInhibitor.cpp index 2ca0f4d6..e3712ce7 100644 --- a/src/managers/input/IdleInhibitor.cpp +++ b/src/managers/input/IdleInhibitor.cpp @@ -5,13 +5,13 @@ #include "../../protocols/core/Compositor.hpp" void CInputManager::newIdleInhibitor(std::any inhibitor) { - const auto PINHIBIT = m_vIdleInhibitors.emplace_back(makeUnique<SIdleInhibitor>()).get(); + const auto PINHIBIT = m_idleInhibitors.emplace_back(makeUnique<SIdleInhibitor>()).get(); PINHIBIT->inhibitor = std::any_cast<SP<CIdleInhibitor>>(inhibitor); Debug::log(LOG, "New idle inhibitor registered for surface {:x}", (uintptr_t)PINHIBIT->inhibitor->surface.get()); PINHIBIT->inhibitor->listeners.destroy = PINHIBIT->inhibitor->resource->events.destroy.registerListener([this, PINHIBIT](std::any data) { - std::erase_if(m_vIdleInhibitors, [PINHIBIT](const auto& other) { return other.get() == PINHIBIT; }); + std::erase_if(m_idleInhibitors, [PINHIBIT](const auto& other) { return other.get() == PINHIBIT; }); recheckIdleInhibitorStatus(); }); @@ -25,14 +25,14 @@ void CInputManager::newIdleInhibitor(std::any inhibitor) { } PINHIBIT->surfaceDestroyListener = WLSurface->m_events.destroy.registerListener( - [this, PINHIBIT](std::any data) { std::erase_if(m_vIdleInhibitors, [PINHIBIT](const auto& other) { return other.get() == PINHIBIT; }); }); + [this, PINHIBIT](std::any data) { std::erase_if(m_idleInhibitors, [PINHIBIT](const auto& other) { return other.get() == PINHIBIT; }); }); recheckIdleInhibitorStatus(); } void CInputManager::recheckIdleInhibitorStatus() { - for (auto const& ii : m_vIdleInhibitors) { + for (auto const& ii : m_idleInhibitors) { if (ii->nonDesktop) { PROTO::idle->setInhibit(true); return; @@ -73,7 +73,7 @@ bool CInputManager::isWindowInhibiting(const PHLWINDOW& w, bool onlyHl) { if (onlyHl) return false; - for (auto const& ii : m_vIdleInhibitors) { + for (auto const& ii : m_idleInhibitors) { if (ii->nonDesktop || !ii->inhibitor) continue; |
