From 9261356bd74fadbc544bec22c16aec62ebba13bd Mon Sep 17 00:00:00 2001 From: Lukas Fleischer Date: Wed, 26 Jul 2023 04:45:00 -0400 Subject: [PATCH] Clear wallpaper from monitor before destroying ouput (#79) Fixes issue #54. --- src/events/Events.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/events/Events.cpp b/src/events/Events.cpp index 7d7591b..0990a64 100644 --- a/src/events/Events.cpp +++ b/src/events/Events.cpp @@ -137,6 +137,7 @@ void Events::handleGlobalRemove(void *data, struct wl_registry *registry, uint32 for (auto& m : g_pHyprpaper->m_vMonitors) { if (m->wayland_name == name) { Debug::log(LOG, "Destroying output %s", m->name.c_str()); + g_pHyprpaper->clearWallpaperFromMonitor(m->name); std::erase_if(g_pHyprpaper->m_vMonitors, [&](const auto& other) { return other->wayland_name == name; }); return; }