xwayland: Don't focus an already focused xwayland window

We've been doing this when clicking on windows, even if they're
already activated. This leads to sending extra WM_TAKE_FOCUS events
as well as re-rendering the decor every mouse click.

Signed-off-by: Derek Foreman <derek.foreman@collabora.com>
dev
Derek Foreman 2 years ago
parent 5afe6c5b39
commit ae4209978c
  1. 3
      xwayland/window-manager.c

@ -980,6 +980,9 @@ weston_wm_window_activate(struct wl_listener *listener, void *data)
window = get_wm_window(surface);
}
if (wm->focus_window == window)
return;
if (window) {
weston_wm_set_net_active_window(wm, window->id);
} else {

Loading…
Cancel
Save