diff options
| author | Vaxry <43317083+vaxerski@users.noreply.github.com> | 2025-01-23 21:55:41 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-01-23 21:55:41 +0100 |
| commit | 0a1ae48a9fd6eb76baad27de98c00f653a55e4ac (patch) | |
| tree | 007cd36eb83d343d2aba49cf0741028c5f554895 /src/render/decorations/CHyprGroupBarDecoration.cpp | |
| parent | ae403e6a05452336abd97e61be2706f6a930d827 (diff) | |
core: move all shared_ptrs from the STL to hyprutils (#9143)
Diffstat (limited to 'src/render/decorations/CHyprGroupBarDecoration.cpp')
| -rw-r--r-- | src/render/decorations/CHyprGroupBarDecoration.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/render/decorations/CHyprGroupBarDecoration.cpp b/src/render/decorations/CHyprGroupBarDecoration.cpp index 4a411b6c..36846fd4 100644 --- a/src/render/decorations/CHyprGroupBarDecoration.cpp +++ b/src/render/decorations/CHyprGroupBarDecoration.cpp @@ -176,11 +176,11 @@ void CHyprGroupBarDecoration::draw(PHLMONITOR pMonitor, float const& a) { CTitleTex* pTitleTex = textureFromTitle(m_dwGroupMembers[WINDOWINDEX]->m_szTitle); if (!pTitleTex) - pTitleTex = m_sTitleTexs.titleTexs - .emplace_back(std::make_unique<CTitleTex>(m_dwGroupMembers[WINDOWINDEX].lock(), - Vector2D{m_fBarWidth * pMonitor->scale, (*PTITLEFONTSIZE + 2L * BAR_TEXT_PAD) * pMonitor->scale}, - pMonitor->scale)) - .get(); + pTitleTex = + m_sTitleTexs.titleTexs + .emplace_back(makeUnique<CTitleTex>(m_dwGroupMembers[WINDOWINDEX].lock(), + Vector2D{m_fBarWidth * pMonitor->scale, (*PTITLEFONTSIZE + 2L * BAR_TEXT_PAD) * pMonitor->scale}, pMonitor->scale)) + .get(); rect.y += std::ceil((rect.height - pTitleTex->texSize.y) / 2.0); rect.height = pTitleTex->texSize.y; rect.width = pTitleTex->texSize.x; @@ -421,7 +421,7 @@ bool CHyprGroupBarDecoration::onEndWindowDragOnDeco(const Vector2D& pos, PHLWIND g_pLayoutManager->getCurrentLayout()->recalculateWindow(pDraggedWindow); if (!pDraggedWindow->getDecorationByType(DECORATION_GROUPBAR)) - pDraggedWindow->addWindowDeco(std::make_unique<CHyprGroupBarDecoration>(pDraggedWindow)); + pDraggedWindow->addWindowDeco(makeUnique<CHyprGroupBarDecoration>(pDraggedWindow)); return true; } |
