window: Check window responsiveness on every window focus

Increase the number of checks whether a window is still responsive and
ping windows on every call to `meta_window_focus()` instead of
`meta_window_activate_full()`. This ensures the window is also pinged in
case normal interaction like clicks on the window happen and a close
dialog will eventually get shown.

Related https://gitlab.gnome.org/GNOME/mutter/issues/395

https://gitlab.gnome.org/GNOME/mutter/merge_requests/891
This commit is contained in:
Jonas Dreßler 2019-10-15 18:29:27 +02:00 committed by Jonas Ådahl
parent 7cc02cf24e
commit d053ccfb18

View File

@ -3750,8 +3750,6 @@ meta_window_activate_full (MetaWindow *window,
meta_window_focus (window, timestamp);
else
meta_workspace_activate_with_focus (window->workspace, window, timestamp);
meta_window_check_alive (window, timestamp);
}
/* This function exists since most of the functionality in window_activate
@ -4772,6 +4770,8 @@ meta_window_focus (MetaWindow *window,
return;
}
meta_window_check_alive (window, timestamp);
META_WINDOW_GET_CLASS (window)->focus (window, timestamp);
if (window->display->event_route == META_EVENT_ROUTE_NORMAL)