mirror of
https://github.com/hyprwm/Hyprland.git
synced 2025-08-10 00:51:58 -07:00
workspacerules: add back on-created-empty functionality (#5452)
* workspacerules: add back on-created-empty functionality * clang format * workspacerules: spawn on-created-empty window while initializing CWorkspace * clang format * configManager: fix typo --------- Co-authored-by: Your Name <you@example.com>
This commit is contained in:
@@ -44,6 +44,9 @@ void CWorkspace::init(PHLWORKSPACE self) {
|
||||
const auto WORKSPACERULE = g_pConfigManager->getWorkspaceRuleFor(self);
|
||||
m_bPersistent = WORKSPACERULE.isPersistent;
|
||||
|
||||
if (auto cmd = WORKSPACERULE.onCreatedEmptyRunCmd)
|
||||
g_pKeybindManager->spawn(*cmd);
|
||||
|
||||
g_pEventManager->postEvent({"createworkspace", m_szName});
|
||||
g_pEventManager->postEvent({"createworkspacev2", std::format("{},{}", m_iID, m_szName)});
|
||||
EMIT_HOOK_EVENT("createWorkspace", this);
|
||||
|
Reference in New Issue
Block a user