From b18a2738e3d9a46be0ea896711f28d7cad61da85 Mon Sep 17 00:00:00 2001 From: vaxerski <43317083+vaxerski@users.noreply.github.com> Date: Tue, 26 Jul 2022 18:22:34 +0200 Subject: schedule recalcs in LS --- src/events/Layers.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/events/Layers.cpp') diff --git a/src/events/Layers.cpp b/src/events/Layers.cpp index cc5d935f..49b626a0 100644 --- a/src/events/Layers.cpp +++ b/src/events/Layers.cpp @@ -89,7 +89,7 @@ void Events::listener_destroyLayerSurface(void* owner, void* data) { // rearrange to fix the reserved areas if (PMONITOR) { g_pHyprRenderer->arrangeLayersForMonitor(PMONITOR->ID); - g_pLayoutManager->getCurrentLayout()->recalculateMonitor(PMONITOR->ID); + PMONITOR->scheduledRecalc = true; // and damage wlr_box geomFixed = {layersurface->geometry.x + PMONITOR->vecPosition.x, layersurface->geometry.y + PMONITOR->vecPosition.y, layersurface->geometry.width, layersurface->geometry.height}; @@ -124,7 +124,7 @@ void Events::listener_mapLayerSurface(void* owner, void* data) { } } layersurface->monitorID = PMONITOR->ID; - g_pLayoutManager->getCurrentLayout()->recalculateMonitor(POLDMON->ID); + PMONITOR->scheduledRecalc = true; g_pHyprRenderer->arrangeLayersForMonitor(POLDMON->ID); } @@ -229,7 +229,7 @@ void Events::listener_commitLayerSurface(void* owner, void* data) { } layersurface->monitorID = PMONITOR->ID; - g_pLayoutManager->getCurrentLayout()->recalculateMonitor(POLDMON->ID); + PMONITOR->scheduledRecalc = true; g_pHyprRenderer->arrangeLayersForMonitor(POLDMON->ID); } @@ -249,7 +249,7 @@ void Events::listener_commitLayerSurface(void* owner, void* data) { g_pHyprRenderer->arrangeLayersForMonitor(PMONITOR->ID); - g_pLayoutManager->getCurrentLayout()->recalculateMonitor(PMONITOR->ID); + PMONITOR->scheduledRecalc = true; } layersurface->position = Vector2D(layersurface->geometry.x, layersurface->geometry.y); -- cgit v1.2.3