diff --git a/easymotionDeco.cpp b/easymotionDeco.cpp index 8d0f199..941de87 100644 --- a/easymotionDeco.cpp +++ b/easymotionDeco.cpp @@ -139,21 +139,21 @@ void CHyprEasyLabel::draw(PHLMONITOR pMonitor, float const &a) { if (motionBox.w < 1 || motionBox.h < 1) return; - g_pHyprOpenGL->scissor(&motionBox); - g_pHyprOpenGL->renderRect(&motionBox, m_cBackgroundColor, scaledRounding); + g_pHyprOpenGL->scissor(motionBox); + g_pHyprOpenGL->renderRect(motionBox, m_cBackgroundColor, scaledRounding); if (m_iBorderSize) { CBox borderBox = {DECOBOX.x, DECOBOX.y, static_cast(layoutWidth), static_cast(layoutHeight)}; borderBox.translate(pMonitor->vecPosition*-1).scale(pMonitor->scale).round(); if (borderBox.w >= 1 && borderBox.h >= 1) { - g_pHyprOpenGL->renderBorder(&borderBox, m_cBorderGradient, scaledRounding, m_iBorderSize * pMonitor->scale, a); + g_pHyprOpenGL->renderBorder(borderBox, m_cBorderGradient, scaledRounding, m_iBorderSize * pMonitor->scale, a); } } - g_pHyprOpenGL->renderTexture(m_tTextTex, &motionBox, a); + g_pHyprOpenGL->renderTexture(m_tTextTex, motionBox, a); - g_pHyprOpenGL->scissor((CBox*)nullptr); + g_pHyprOpenGL->scissor(nullptr); } eDecorationType CHyprEasyLabel::getDecorationType() { diff --git a/main.cpp b/main.cpp index f89657c..65db3a5 100644 --- a/main.cpp +++ b/main.cpp @@ -56,7 +56,7 @@ void addEasyMotionKeybinds() void addLabelToWindow(PHLWINDOW window, SMotionActionDesc *actionDesc, std::string &label) { - std::unique_ptr motionlabel = std::make_unique(window, actionDesc); + UP motionlabel = makeUnique(window, actionDesc); motionlabel.get()->m_szLabel = label; g_pGlobalState->motionLabels.push_back(motionlabel.get()); HyprlandAPI::addWindowDecoration(PHANDLE, window, std::move(motionlabel));