Skip to content

Commit

Permalink
Fix pixel gaps with recent CBox changes
Browse files Browse the repository at this point in the history
  • Loading branch information
outfoxxed committed Nov 8, 2023
1 parent 47cb4a9 commit 4db9b1f
Showing 1 changed file with 11 additions and 4 deletions.
15 changes: 11 additions & 4 deletions src/Hy3Layout.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1434,8 +1434,12 @@ void Hy3Layout::applyNodeDataToWindow(Hy3Node* node, bool no_animation) {
&& g_pCompositor->getWorkspaceByID(window->m_iWorkspaceID)->m_efFullscreenMode
== FULLSCREEN_FULL)))
{
window->m_vRealPosition = window->m_vPosition;
window->m_vRealSize = window->m_vSize;

CBox wb = {window->m_vPosition, window->m_vSize};
wb.round();

window->m_vRealPosition = wb.pos();
window->m_vRealSize = wb.size();

window->updateWindowDecos();

Expand All @@ -1458,8 +1462,11 @@ void Hy3Layout::applyNodeDataToWindow(Hy3Node* node, bool no_animation) {
calcPos = calcPos + reserved_area.topLeft;
calcSize = calcSize - (reserved_area.topLeft - reserved_area.bottomRight);

window->m_vRealPosition = calcPos;
window->m_vRealSize = calcSize;
CBox wb = {calcPos, calcSize};
wb.round();

window->m_vRealPosition = wb.pos();
window->m_vRealSize = wb.size();

g_pXWaylandManager->setWindowSize(window, calcSize);

Expand Down

0 comments on commit 4db9b1f

Please sign in to comment.