diff options
| author | vaxerski <43317083+vaxerski@users.noreply.github.com> | 2023-05-23 14:26:38 +0200 |
|---|---|---|
| committer | vaxerski <43317083+vaxerski@users.noreply.github.com> | 2023-05-23 14:26:38 +0200 |
| commit | eb1f832fcec5838053c6b031b656e4f949ada57b (patch) | |
| tree | 5e945f2953ff2217976f77e9da67de5727c466f1 /src | |
| parent | 799add8659fe896579f050ee0ddeda63a2df5b91 (diff) | |
decos: recalc on add
Diffstat (limited to 'src')
| -rw-r--r-- | src/Window.hpp | 3 | ||||
| -rw-r--r-- | src/layout/DwindleLayout.cpp | 2 | ||||
| -rw-r--r-- | src/managers/KeybindManager.cpp | 4 | ||||
| -rw-r--r-- | src/plugins/PluginAPI.cpp | 3 |
4 files changed, 11 insertions, 1 deletions
diff --git a/src/Window.hpp b/src/Window.hpp index 3dbcbe5b..78f60721 100644 --- a/src/Window.hpp +++ b/src/Window.hpp @@ -10,7 +10,8 @@ #include "helpers/Vector2D.hpp" #include "helpers/WLSurface.hpp" -enum eIdleInhibitMode { +enum eIdleInhibitMode +{ IDLEINHIBIT_NONE = 0, IDLEINHIBIT_ALWAYS, IDLEINHIBIT_FULLSCREEN, diff --git a/src/layout/DwindleLayout.cpp b/src/layout/DwindleLayout.cpp index a1b7d6d7..523283ec 100644 --- a/src/layout/DwindleLayout.cpp +++ b/src/layout/DwindleLayout.cpp @@ -316,6 +316,8 @@ void CHyprDwindleLayout::onWindowCreatedTiling(CWindow* pWindow) { OPENINGON->pWindow->insertWindowToGroup(pWindow); pWindow->m_dWindowDecorations.emplace_back(std::make_unique<CHyprGroupBarDecoration>(pWindow)); + pWindow->updateWindowDecos(); + recalculateWindow(pWindow); return; } diff --git a/src/managers/KeybindManager.cpp b/src/managers/KeybindManager.cpp index 8dad6700..e3e56ef7 100644 --- a/src/managers/KeybindManager.cpp +++ b/src/managers/KeybindManager.cpp @@ -1165,6 +1165,7 @@ void CKeybindManager::toggleGroup(std::string args) { PWINDOW->m_dWindowDecorations.emplace_back(std::make_unique<CHyprGroupBarDecoration>(PWINDOW)); PWINDOW->updateWindowDecos(); + g_pLayoutManager->getCurrentLayout()->recalculateWindow(PWINDOW); } else { if (PWINDOW->m_sGroupData.pNextWindow == PWINDOW) { PWINDOW->m_sGroupData.pNextWindow = nullptr; @@ -1999,6 +2000,9 @@ void CKeybindManager::moveIntoGroup(std::string args) { PWINDOWINDIR->insertWindowToGroup(PWINDOW); PWINDOW->m_dWindowDecorations.emplace_back(std::make_unique<CHyprGroupBarDecoration>(PWINDOW)); + + PWINDOW->updateWindowDecos(); + g_pLayoutManager->getCurrentLayout()->recalculateWindow(PWINDOW); } void CKeybindManager::moveOutOfGroup(std::string args) { diff --git a/src/plugins/PluginAPI.cpp b/src/plugins/PluginAPI.cpp index 48500ee4..add2b833 100644 --- a/src/plugins/PluginAPI.cpp +++ b/src/plugins/PluginAPI.cpp @@ -120,6 +120,9 @@ APICALL bool HyprlandAPI::addWindowDecoration(HANDLE handle, CWindow* pWindow, I pWindow->m_dWindowDecorations.emplace_back(pDecoration); + pWindow->updateWindowDecos(); + g_pLayoutManager->getCurrentLayout()->recalculateWindow(pWindow); + return true; } |
