core: add --verify-config to verify the config with Hyprland

fixes #9135
This commit is contained in:
Vaxry 2025-01-24 20:30:12 +00:00
parent 80b2fd135b
commit d8f79d7678
7 changed files with 69 additions and 25 deletions

View file

@ -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