From 4cee94b91c9337036f3ea94f80cf8259c5c51cb4 Mon Sep 17 00:00:00 2001 From: 1over137 <22680475+1over137@users.noreply.github.com> Date: Sun, 14 Jan 2024 13:56:35 +0000 Subject: [PATCH] fractional: Set preferred scale on monitor config reload (#4406) --- src/render/Renderer.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/render/Renderer.cpp b/src/render/Renderer.cpp index 6d5af8d9..cf246c7c 100644 --- a/src/render/Renderer.cpp +++ b/src/render/Renderer.cpp @@ -2101,6 +2101,13 @@ bool CHyprRenderer::applyMonitorRule(CMonitor* pMonitor, SMonitorRule* pMonitorR wlr_damage_ring_set_bounds(&pMonitor->damage, pMonitor->vecTransformedSize.x, pMonitor->vecTransformedSize.y); + // Set scale for all surfaces on this monitor, needed for some clients + // but not on unsafe state to avoid crashes + if (!g_pCompositor->m_bUnsafeState) { + for (auto& w : g_pCompositor->m_vWindows) { + w->updateSurfaceScaleTransformDetails(); + } + } // updato us arrangeLayersForMonitor(pMonitor->ID);