summaryrefslogtreecommitdiff
path: root/src/layout/MasterLayout.cpp
diff options
context:
space:
mode:
authorVaxry <43317083+vaxerski@users.noreply.github.com>2023-12-10 16:28:12 +0000
committerGitHub <noreply@github.com>2023-12-10 16:28:12 +0000
commit9f5b9053c6fb7942a0ff27dc61fc6874e4354888 (patch)
treef117abba6e6b5c2f4a673e67039225f7fca04be2 /src/layout/MasterLayout.cpp
parentb3dc58e1047cba0778831bdb069c3ceba6ec216e (diff)
internal: Remake borders as window decorations (#4104)
Diffstat (limited to 'src/layout/MasterLayout.cpp')
-rw-r--r--src/layout/MasterLayout.cpp16
1 files changed, 6 insertions, 10 deletions
diff --git a/src/layout/MasterLayout.cpp b/src/layout/MasterLayout.cpp
index 3977d8f6..8b12d669 100644
--- a/src/layout/MasterLayout.cpp
+++ b/src/layout/MasterLayout.cpp
@@ -667,24 +667,20 @@ void CHyprMasterLayout::applyNodeDataToWindow(SMasterNodeData* pNode) {
PWINDOW->m_sSpecialRenderData.rounding = false;
PWINDOW->m_sSpecialRenderData.shadow = false;
- const auto RESERVED = PWINDOW->getFullWindowReservedArea();
-
- const int BORDERSIZE = PWINDOW->getRealBorderSize();
+ PWINDOW->updateWindowDecos();
- PWINDOW->m_vRealPosition = PWINDOW->m_vPosition + Vector2D(BORDERSIZE, BORDERSIZE) + RESERVED.topLeft;
- PWINDOW->m_vRealSize = PWINDOW->m_vSize - Vector2D(2 * BORDERSIZE, 2 * BORDERSIZE) - (RESERVED.topLeft + RESERVED.bottomRight);
+ const auto RESERVED = PWINDOW->getFullWindowReservedArea();
- PWINDOW->updateWindowDecos();
+ PWINDOW->m_vRealPosition = PWINDOW->m_vPosition + RESERVED.topLeft;
+ PWINDOW->m_vRealSize = PWINDOW->m_vSize - (RESERVED.topLeft + RESERVED.bottomRight);
g_pXWaylandManager->setWindowSize(PWINDOW, PWINDOW->m_vRealSize.goalv());
return;
}
- const int BORDERSIZE = PWINDOW->getRealBorderSize();
-
- auto calcPos = PWINDOW->m_vPosition + Vector2D(BORDERSIZE, BORDERSIZE);
- auto calcSize = PWINDOW->m_vSize - Vector2D(2 * BORDERSIZE, 2 * BORDERSIZE);
+ auto calcPos = PWINDOW->m_vPosition;
+ auto calcSize = PWINDOW->m_vSize;
const auto OFFSETTOPLEFT = Vector2D(DISPLAYLEFT ? gapsOut : gapsIn, DISPLAYTOP ? gapsOut : gapsIn);