mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2025-10-31 22:25:21 -04:00
Merge pull request #670 from Ongy/xwayland_unmanaged
add xwayland unmanaged tests to support dmenu
This commit is contained in:
commit
c2ba1869ce
8 changed files with 60 additions and 2 deletions
|
|
@ -445,13 +445,17 @@ void view_init(struct roots_view *view, struct roots_desktop *desktop) {
|
|||
view_damage_whole(view);
|
||||
}
|
||||
|
||||
void view_setup(struct roots_view *view) {
|
||||
void view_initial_focus(struct roots_view *view) {
|
||||
struct roots_input *input = view->desktop->server->input;
|
||||
// TODO what seat gets focus? the one with the last input event?
|
||||
struct roots_seat *seat;
|
||||
wl_list_for_each(seat, &input->seats, link) {
|
||||
roots_seat_set_focus(seat, view);
|
||||
}
|
||||
}
|
||||
|
||||
void view_setup(struct roots_view *view) {
|
||||
view_initial_focus(view);
|
||||
|
||||
view_center(view);
|
||||
view_update_output(view, NULL);
|
||||
|
|
|
|||
|
|
@ -721,7 +721,7 @@ void roots_seat_set_focus(struct roots_seat *seat, struct roots_view *view) {
|
|||
|
||||
#ifdef WLR_HAS_XWAYLAND
|
||||
if (view && view->type == ROOTS_XWAYLAND_VIEW &&
|
||||
view->xwayland_surface->override_redirect) {
|
||||
wlr_xwayland_surface_is_unmanaged(view->xwayland_surface)) {
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -350,5 +350,7 @@ void handle_xwayland_surface(struct wl_listener *listener, void *data) {
|
|||
}
|
||||
|
||||
view_setup(view);
|
||||
} else {
|
||||
view_initial_focus(view);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue