summaryrefslogtreecommitdiff
path: root/src/managers
diff options
context:
space:
mode:
Diffstat (limited to 'src/managers')
-rw-r--r--src/managers/AnimationManager.cpp3
-rw-r--r--src/managers/KeybindManager.cpp7
2 files changed, 7 insertions, 3 deletions
diff --git a/src/managers/AnimationManager.cpp b/src/managers/AnimationManager.cpp
index f884acdd..964f7cfa 100644
--- a/src/managers/AnimationManager.cpp
+++ b/src/managers/AnimationManager.cpp
@@ -34,7 +34,8 @@ static int wlTick(SP<CEventLoopTimer> self, void* data) {
CHyprAnimationManager::CHyprAnimationManager() {
m_pAnimationTimer = SP<CEventLoopTimer>(new CEventLoopTimer(std::chrono::microseconds(500), wlTick, nullptr));
- g_pEventLoopManager->addTimer(m_pAnimationTimer);
+ if (g_pEventLoopManager) // null in --verify-config mode
+ g_pEventLoopManager->addTimer(m_pAnimationTimer);
addBezierWithName("linear", Vector2D(0.0, 0.0), Vector2D(1.0, 1.0));
}
diff --git a/src/managers/KeybindManager.cpp b/src/managers/KeybindManager.cpp
index 4706c1e1..e2191bc6 100644
--- a/src/managers/KeybindManager.cpp
+++ b/src/managers/KeybindManager.cpp
@@ -172,8 +172,11 @@ CKeybindManager::CKeybindManager() {
},
nullptr);
- g_pEventLoopManager->addTimer(m_pLongPressTimer);
- g_pEventLoopManager->addTimer(m_pRepeatKeyTimer);
+ // null in --verify-config mode
+ if (g_pEventLoopManager) {
+ g_pEventLoopManager->addTimer(m_pLongPressTimer);
+ g_pEventLoopManager->addTimer(m_pRepeatKeyTimer);
+ }
static auto P = g_pHookSystem->hookDynamic("configReloaded", [this](void* hk, SCallbackInfo& info, std::any param) {
// clear cuz realloc'd