diff options
author | vaxerski <[email protected]> | 2022-11-09 10:56:36 +0000 |
---|---|---|
committer | vaxerski <[email protected]> | 2022-11-09 10:56:49 +0000 |
commit | d0b3cdc835f8170feee8a18a64178496a852d6ae (patch) | |
tree | 472bcb04c1e0daf4e4b6e845dddd3bcd4d4643a7 /src | |
parent | 1cf829c889ea50476ac0b45d9031e6c1a7da0f55 (diff) | |
download | Hyprland-d0b3cdc835f8170feee8a18a64178496a852d6ae.tar.gz Hyprland-d0b3cdc835f8170feee8a18a64178496a852d6ae.zip |
Fix crashes with DS and mirrors
Diffstat (limited to 'src')
-rw-r--r-- | src/render/Renderer.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/render/Renderer.cpp b/src/render/Renderer.cpp index f90b729b..aed7d212 100644 --- a/src/render/Renderer.cpp +++ b/src/render/Renderer.cpp @@ -565,9 +565,12 @@ void countSubsurfacesIter(wlr_surface* pSurface, int x, int y, void* data) { } bool CHyprRenderer::attemptDirectScanout(CMonitor* pMonitor) { + if (!pMonitor->mirrors.empty()) + return false; // do not DS if this monitor is being mirrored. Will break the functionality. + const auto PWORKSPACE = g_pCompositor->getWorkspaceByID(pMonitor->activeWorkspace); - if (!PWORKSPACE->m_bHasFullscreenWindow || g_pInputManager->m_sDrag.drag || g_pCompositor->m_sSeat.exclusiveClient) + if (!PWORKSPACE || !PWORKSPACE->m_bHasFullscreenWindow || g_pInputManager->m_sDrag.drag || g_pCompositor->m_sSeat.exclusiveClient) return false; const auto PCANDIDATE = g_pCompositor->getFullscreenWindowOnWorkspace(PWORKSPACE->m_iID); |