From bb958a9e139d6ae90d45fe360287d33e229f971e Mon Sep 17 00:00:00 2001 From: Tom Englund Date: Fri, 4 Jul 2025 09:58:37 +0200 Subject: pass: overload TexPass constructor overload it with a rvalue to allow us to move the data directly avoiding an extra copy. because SRenderData is not trivially copyable. --- src/protocols/core/DataDevice.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/protocols/core/DataDevice.cpp') diff --git a/src/protocols/core/DataDevice.cpp b/src/protocols/core/DataDevice.cpp index ec075e8b..730113f1 100644 --- a/src/protocols/core/DataDevice.cpp +++ b/src/protocols/core/DataDevice.cpp @@ -814,7 +814,7 @@ void CWLDataDeviceProtocol::renderDND(PHLMONITOR pMonitor, const Time::steady_tp CTexPassElement::SRenderData data; data.tex = m_dnd.dndSurface->m_current.texture; data.box = box; - g_pHyprRenderer->m_renderPass.add(makeShared(data)); + g_pHyprRenderer->m_renderPass.add(makeShared(std::move(data))); CBox damageBox = CBox{surfacePos, m_dnd.dndSurface->m_current.size}.expand(5); g_pHyprRenderer->damageBox(damageBox); -- cgit v1.2.3