diff options
| author | Vaxry <43317083+vaxerski@users.noreply.github.com> | 2023-12-10 16:28:12 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-12-10 16:28:12 +0000 |
| commit | 9f5b9053c6fb7942a0ff27dc61fc6874e4354888 (patch) | |
| tree | f117abba6e6b5c2f4a673e67039225f7fca04be2 /src/render/decorations/CHyprDropShadowDecoration.cpp | |
| parent | b3dc58e1047cba0778831bdb069c3ceba6ec216e (diff) | |
internal: Remake borders as window decorations (#4104)
Diffstat (limited to 'src/render/decorations/CHyprDropShadowDecoration.cpp')
| -rw-r--r-- | src/render/decorations/CHyprDropShadowDecoration.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/render/decorations/CHyprDropShadowDecoration.cpp b/src/render/decorations/CHyprDropShadowDecoration.cpp index bbf6def4..5e70b639 100644 --- a/src/render/decorations/CHyprDropShadowDecoration.cpp +++ b/src/render/decorations/CHyprDropShadowDecoration.cpp @@ -116,13 +116,13 @@ void CHyprDropShadowDecoration::draw(CMonitor* pMonitor, float a, const Vector2D CBox withDecos = m_bLastWindowBoxWithDecos; // get window box - windowBox.translate(-pMonitor->vecPosition + WORKSPACEOFFSET).scale(pMonitor->scale).round(); - withDecos.translate(-pMonitor->vecPosition + WORKSPACEOFFSET).scale(pMonitor->scale).round(); + windowBox.translate(-pMonitor->vecPosition + WORKSPACEOFFSET); + withDecos.translate(-pMonitor->vecPosition + WORKSPACEOFFSET); - auto scaledDecoExtents = withDecos.extentsFrom(windowBox).round(); + auto extentss = withDecos.extentsFrom(windowBox); // add extents - windowBox.addExtents(scaledDecoExtents).round(); + windowBox.addExtents(extentss).scale(pMonitor->scale).round(); if (windowBox.width < 1 || windowBox.height < 1) return; // prevent assert failed @@ -159,7 +159,7 @@ void CHyprDropShadowDecoration::draw(CMonitor* pMonitor, float a, const Vector2D g_pHyprOpenGL->m_RenderData.damage = saveDamage; } else { - g_pHyprOpenGL->renderRoundedShadow(&fullBox, ROUNDING * pMonitor->scale, *PSHADOWSIZE * pMonitor->scale, a); + g_pHyprOpenGL->renderRoundedShadow(&fullBox, ROUNDING * pMonitor->scale, *PSHADOWSIZE * pMonitor->scale, m_pWindow->m_cRealShadowColor.col(), a); } if (m_seExtents != m_seReportedExtents) |
