From 4b20d4f1add40130653b9a3f2351eb44e0e0df4b Mon Sep 17 00:00:00 2001 From: vaxerski <43317083+vaxerski@users.noreply.github.com> Date: Tue, 28 Feb 2023 19:36:36 +0000 Subject: Added decoration reserved area --- src/managers/XWaylandManager.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/managers/XWaylandManager.cpp') diff --git a/src/managers/XWaylandManager.cpp b/src/managers/XWaylandManager.cpp index d67441c7..3f8f51e8 100644 --- a/src/managers/XWaylandManager.cpp +++ b/src/managers/XWaylandManager.cpp @@ -136,7 +136,11 @@ void CHyprXWaylandManager::sendCloseWindow(CWindow* pWindow) { } } -void CHyprXWaylandManager::setWindowSize(CWindow* pWindow, const Vector2D& size, bool force) { +void CHyprXWaylandManager::setWindowSize(CWindow* pWindow, Vector2D size, bool force) { + + const auto RESERVED = pWindow->getFullWindowReservedArea(); + + size = size - RESERVED.topLeft - RESERVED.bottomRight; if (!force && ((pWindow->m_vReportedSize == size && pWindow->m_vRealPosition.vec() == pWindow->m_vReportedPosition) || (pWindow->m_vReportedSize == size && !pWindow->m_bIsX11))) -- cgit v1.2.3