aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/managers/XWaylandManager.cpp
diff options
context:
space:
mode:
authortrianta <[email protected]>2024-08-25 09:37:03 -0500
committerGitHub <[email protected]>2024-08-25 16:37:03 +0200
commitb672118f9238a48a18efd741cbcda387c5552238 (patch)
tree80e02da0c9ecc419c54ee12d5b3939d1516527eb /src/managers/XWaylandManager.cpp
parentaac90d92797825a65b9faab038586a3b88448667 (diff)
downloadHyprland-b672118f9238a48a18efd741cbcda387c5552238.tar.gz
Hyprland-b672118f9238a48a18efd741cbcda387c5552238.zip
xwayland: deactivate xwayland focus if wayland is focused (#7458)
* xwayland: deactivate xwayland focus if wayland is focused * xwayland: deactivate last xwayland surface after focusing wayland
Diffstat (limited to 'src/managers/XWaylandManager.cpp')
-rw-r--r--src/managers/XWaylandManager.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/managers/XWaylandManager.cpp b/src/managers/XWaylandManager.cpp
index f329dbe1..2f0632e0 100644
--- a/src/managers/XWaylandManager.cpp
+++ b/src/managers/XWaylandManager.cpp
@@ -43,8 +43,11 @@ void CHyprXWaylandManager::activateSurface(SP<CWLSurfaceResource> pSurface, bool
w->m_pXWaylandSurface->restackToTop();
}
w->m_pXWaylandSurface->activate(activate);
- } else
+ } else {
w->m_pXDGSurface->toplevel->setActive(activate);
+ if (g_pCompositor->m_pLastFocus && g_pCompositor->m_pLastWindow->m_bIsX11)
+ activateSurface(g_pCompositor->m_pLastFocus.lock(), false);
+ }
}
}