diff options
| author | vaxerski <43317083+vaxerski@users.noreply.github.com> | 2022-03-22 20:53:11 +0100 |
|---|---|---|
| committer | vaxerski <43317083+vaxerski@users.noreply.github.com> | 2022-03-22 20:53:11 +0100 |
| commit | e6a848adc0648bed29bb232ca5ee421ac6f575f9 (patch) | |
| tree | ac4fb19b4aa248019c1ed8bdb60919333a1b359e /src/Compositor.cpp | |
| parent | b6f3aa5d01d5f02f92167674bc29f4379fd5afbb (diff) | |
handle modals a bit better
Diffstat (limited to 'src/Compositor.cpp')
| -rw-r--r-- | src/Compositor.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/Compositor.cpp b/src/Compositor.cpp index 4d3cfc85..e747e597 100644 --- a/src/Compositor.cpp +++ b/src/Compositor.cpp @@ -249,7 +249,7 @@ CWindow* CCompositor::vectorToWindowIdeal(const Vector2D& pos) { // TODO: make an actual Z-system for (auto& w : m_lWindows) { wlr_box box = {w.m_vRealPosition.x, w.m_vRealPosition.y, w.m_vRealSize.x, w.m_vRealSize.y}; - if (w.m_bIsFloating && wlr_box_contains_point(&box, m_sWLRCursor->x, m_sWLRCursor->y) && isWorkspaceVisible(w.m_iWorkspaceID) && !w.m_bIsModal) + if (w.m_bIsFloating && wlr_box_contains_point(&box, m_sWLRCursor->x, m_sWLRCursor->y) && isWorkspaceVisible(w.m_iWorkspaceID)) return &w; } @@ -339,6 +339,9 @@ bool CCompositor::windowValidMapped(CWindow* pWindow) { if (pWindow->m_bIsX11 && !pWindow->m_bMappedX11) return false; + if (!pWindow->m_bIsMapped) + return false; + if (!g_pXWaylandManager->getWindowSurface(pWindow)) return false; |
