From 16aeb24bc1395b46d675ec3522ed452e487f5b69 Mon Sep 17 00:00:00 2001 From: Vaxry Date: Sun, 26 Jan 2025 14:40:42 +0000 Subject: core: make persistent workspaces always follow the config instead of just staying after open, they will now be enforced on their respective monitors fixes #8769 --- src/config/ConfigManager.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/config/ConfigManager.cpp') diff --git a/src/config/ConfigManager.cpp b/src/config/ConfigManager.cpp index fd4783da..93289bf7 100644 --- a/src/config/ConfigManager.cpp +++ b/src/config/ConfigManager.cpp @@ -1034,6 +1034,10 @@ void CConfigManager::postConfigReload(const Hyprlang::CParseResult& result) { // update plugins handlePluginLoads(); + // update persistent workspaces + if (!isFirstLaunch) + ensurePersistentWorkspacesPresent(); + EMIT_HOOK_EVENT("configReloaded", nullptr); if (g_pEventManager) g_pEventManager->postEvent(SHyprIPCEvent{"configreloaded", ""}); @@ -2830,3 +2834,7 @@ std::string SConfigOptionDescription::jsonify() const { return json; } + +void CConfigManager::ensurePersistentWorkspacesPresent() { + g_pCompositor->ensurePersistentWorkspacesPresent(m_vWorkspaceRules); +} -- cgit v1.2.3