shell: Reset focus for all seats on activation

Rather than using a single hardcoded seat to activate new windows within
a compositor, reset the focus for all seats.

Signed-off-by: Daniel Stone <daniel@fooishbar.org>
Daniel Stone 13 years ago committed by Kristian Høgsberg
parent 162f78af68
commit b21046836f
  1. 8
      src/shell.c

@ -2054,6 +2054,7 @@ map(struct desktop_shell *shell, struct weston_surface *surface,
struct shell_surface *shsurf; struct shell_surface *shsurf;
enum shell_surface_type surface_type = SHELL_SURFACE_NONE; enum shell_surface_type surface_type = SHELL_SURFACE_NONE;
struct weston_surface *parent; struct weston_surface *parent;
struct weston_seat *seat;
int panel_height = 0; int panel_height = 0;
shsurf = get_shell_surface(surface); shsurf = get_shell_surface(surface);
@ -2152,9 +2153,10 @@ map(struct desktop_shell *shell, struct weston_surface *surface,
case SHELL_SURFACE_TOPLEVEL: case SHELL_SURFACE_TOPLEVEL:
case SHELL_SURFACE_FULLSCREEN: case SHELL_SURFACE_FULLSCREEN:
case SHELL_SURFACE_MAXIMIZED: case SHELL_SURFACE_MAXIMIZED:
if (!shell->locked) if (!shell->locked) {
activate(shell, surface, wl_list_for_each(seat, &compositor->seat_list, link)
(struct weston_seat *) compositor->seat); activate(shell, surface, seat);
}
break; break;
default: default:
break; break;

Loading…
Cancel
Save