summaryrefslogtreecommitdiff
path: root/src/managers/KeybindManager.cpp
diff options
context:
space:
mode:
authortrianta <56975502+Trimutex@users.noreply.github.com>2024-09-07 14:54:33 -0500
committerGitHub <noreply@github.com>2024-09-07 20:54:33 +0100
commit70add904c40924a761059e4009a8c0f1e43d76a3 (patch)
tree0c359796ef48aefc9b6cff3a19110909406a21b4 /src/managers/KeybindManager.cpp
parent5ca48231287d67e75a3f21dbdbc47d6dc65752c4 (diff)
config: add exec-shutdown for running commands on shutdown (#7683)
* config: add exec-shutdown for running commands on shutdown * compositor: delay stopping until after exec-shutdown
Diffstat (limited to 'src/managers/KeybindManager.cpp')
-rw-r--r--src/managers/KeybindManager.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/managers/KeybindManager.cpp b/src/managers/KeybindManager.cpp
index 2db9f375..2f593d74 100644
--- a/src/managers/KeybindManager.cpp
+++ b/src/managers/KeybindManager.cpp
@@ -1781,6 +1781,11 @@ SDispatchResult CKeybindManager::renameWorkspace(std::string args) {
}
SDispatchResult CKeybindManager::exitHyprland(std::string argz) {
+ g_pConfigManager->dispatchExecShutdown();
+
+ if (g_pCompositor->m_bFinalRequests)
+ return {}; // Exiting deferred until requests complete
+
g_pCompositor->stopCompositor();
return {};
}