summaryrefslogtreecommitdiff
path: root/src/desktop/view/LayerSurface.cpp
diff options
context:
space:
mode:
authorUjinT34 <41110182+UjinT34@users.noreply.github.com>2026-03-07 16:13:34 +0300
committerGitHub <noreply@github.com>2026-03-07 13:13:34 +0000
commit966f20d305345b3042dc1d37a1dd8833f3a4783b (patch)
tree3e8515b7a0f6fde7bf3137aac7124ae90e5951ec /src/desktop/view/LayerSurface.cpp
parent32e75e3e320fb66ab517a378df645f3d29b3a209 (diff)
renderer: refactor resources and flags (#13471)
Diffstat (limited to 'src/desktop/view/LayerSurface.cpp')
-rw-r--r--src/desktop/view/LayerSurface.cpp9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/desktop/view/LayerSurface.cpp b/src/desktop/view/LayerSurface.cpp
index a10c9d4d..1b2a3288 100644
--- a/src/desktop/view/LayerSurface.cpp
+++ b/src/desktop/view/LayerSurface.cpp
@@ -77,13 +77,8 @@ CLayerSurface::CLayerSurface(SP<CLayerShellResource> resource_) : IView(CWLSurfa
}
CLayerSurface::~CLayerSurface() {
- if (!g_pHyprOpenGL)
- return;
-
if (m_wlSurface)
m_wlSurface->unassign();
- g_pHyprRenderer->makeEGLCurrent();
- std::erase_if(g_pHyprOpenGL->m_layerFramebuffers, [&](const auto& other) { return other.first.expired() || other.first.lock() == m_self.lock(); });
for (auto const& mon : g_pCompositor->m_realMonitors) {
for (auto& lsl : mon->m_layerSurfaceLayers) {
@@ -315,7 +310,7 @@ void CLayerSurface::onCommit() {
return;
if (m_layer == ZWLR_LAYER_SHELL_V1_LAYER_BACKGROUND || m_layer == ZWLR_LAYER_SHELL_V1_LAYER_BOTTOM)
- g_pHyprOpenGL->markBlurDirtyForMonitor(PMONITOR); // so that blur is recalc'd
+ PMONITOR->m_blurFBDirty = true;
CBox geomFixed = {m_geometry.x, m_geometry.y, m_geometry.width, m_geometry.height};
g_pHyprRenderer->damageBox(geomFixed);
@@ -340,7 +335,7 @@ void CLayerSurface::onCommit() {
*m_alpha = PMONITOR->inFullscreenMode() ? (m_layer >= ZWLR_LAYER_SHELL_V1_LAYER_OVERLAY ? 1.F : 0.F) : 1.F;
if (m_layer == ZWLR_LAYER_SHELL_V1_LAYER_BACKGROUND || m_layer == ZWLR_LAYER_SHELL_V1_LAYER_BOTTOM)
- g_pHyprOpenGL->markBlurDirtyForMonitor(PMONITOR); // so that blur is recalc'd
+ PMONITOR->m_blurFBDirty = true; // so that blur is recalc'd
}
g_pHyprRenderer->arrangeLayersForMonitor(PMONITOR->m_id);