fix: emit fullscreen event and update window rules+decos on fullscreen

This commit is contained in:
outfoxxed 2024-06-07 13:16:59 -07:00
parent 3025a015ea
commit 2728dbed6a
No known key found for this signature in database
GPG key ID: 4C88A185FB89301E
2 changed files with 9 additions and 0 deletions

View file

@ -1,5 +1,8 @@
# Changelog
# Upcoming
- Fixed IPC and wlr-foreign-toplevel not getting fullscreen and maximize events.
## hl0.40.0 and before
- Added `hy3:warpcursor` dispatcher to warp cursor to current node.

View file

@ -503,6 +503,12 @@ void Hy3Layout::fullscreenRequestForWindow(
window->m_bIsFullscreen = on;
window->m_pWorkspace->m_bHasFullscreenWindow = !window->m_pWorkspace->m_bHasFullscreenWindow;
window->updateDynamicRules();
window->updateWindowDecos();
g_pEventManager->postEvent(SHyprIPCEvent {"fullscreen", std::to_string((int) on)});
EMIT_HOOK_EVENT("fullscreen", window);
if (!window->m_bIsFullscreen) {
auto* node = this->getNodeFromWindow(window);