Chase wlroots!2434

References: https://gitlab.freedesktop.org/wlroots/wlroots/-/merge_requests/2434
This commit is contained in:
Bill Li 2024-07-14 16:24:14 +08:00 committed by Simon Ser
parent 274a5fcb73
commit fc2796aee8
5 changed files with 10 additions and 10 deletions

View file

@ -71,7 +71,7 @@ static void unmanaged_handle_map(struct wl_listener *listener, void *data) {
surface->set_geometry.notify = unmanaged_handle_set_geometry;
}
if (wlr_xwayland_or_surface_wants_focus(xsurface)) {
if (wlr_xwayland_surface_override_redirect_wants_focus(xsurface)) {
struct sway_seat *seat = input_manager_current_seat();
struct wlr_xwayland *xwayland = server.xwayland.wlr_xwayland;
wlr_xwayland_set_seat(xwayland, seat->wlr_seat);
@ -96,7 +96,7 @@ static void unmanaged_handle_unmap(struct wl_listener *listener, void *data) {
// This simply returns focus to the parent surface if there's one available.
// This seems to handle JetBrains issues.
if (xsurface->parent && xsurface->parent->surface
&& wlr_xwayland_or_surface_wants_focus(xsurface->parent)) {
&& wlr_xwayland_surface_override_redirect_wants_focus(xsurface->parent)) {
seat_set_focus_surface(seat, xsurface->parent->surface, false);
return;
}