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>
This commit is contained in:
@@ -980,6 +980,9 @@ weston_wm_window_activate(struct wl_listener *listener, void *data)
|
|||||||
window = get_wm_window(surface);
|
window = get_wm_window(surface);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (wm->focus_window == window)
|
||||||
|
return;
|
||||||
|
|
||||||
if (window) {
|
if (window) {
|
||||||
weston_wm_set_net_active_window(wm, window->id);
|
weston_wm_set_net_active_window(wm, window->id);
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user