aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorvaxerski <[email protected]>2023-03-21 17:46:26 +0000
committervaxerski <[email protected]>2023-03-21 17:46:26 +0000
commitadf5d8a114362a5d32013e95f254b85be048dbdb (patch)
treec0737541c6303b373e92ca22bdaf13ecd8f88d5d
parentcb229f64360502c6774e7242fa353254dcacc931 (diff)
downloadHyprland-adf5d8a114362a5d32013e95f254b85be048dbdb.tar.gz
Hyprland-adf5d8a114362a5d32013e95f254b85be048dbdb.zip
monitors: update surface outputs on recover from unsafe
-rw-r--r--src/events/Monitors.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/events/Monitors.cpp b/src/events/Monitors.cpp
index f6b3ed9f..0412f43e 100644
--- a/src/events/Monitors.cpp
+++ b/src/events/Monitors.cpp
@@ -101,6 +101,13 @@ void Events::listener_newOutput(wl_listener* listener, void* data) {
const auto POS = PNEWMONITOR->vecPosition + PNEWMONITOR->vecSize / 2.f;
if (g_pCompositor->m_sSeat.mouse)
wlr_cursor_warp(g_pCompositor->m_sWLRCursor, g_pCompositor->m_sSeat.mouse->mouse, POS.x, POS.y);
+ } else {
+ for (auto& w : g_pCompositor->m_vWindows) {
+ if (w->m_iMonitorID == PNEWMONITOR->ID) {
+ w->m_iLastSurfaceMonitorID = -1;
+ w->updateSurfaceOutputs();
+ }
+ }
}
}