MetaWindow: add a public method for checking if the application is responding
Add meta_window_check_alive(), which is a simple wrapper over meta_display_ping_window(), and takes care of showing the "Application is not responding dialog" if needed. https://bugzilla.gnome.org/show_bug.cgi?id=684340
This commit is contained in:
@ -133,6 +133,18 @@ delete_ping_timeout_func (MetaDisplay *display,
|
||||
g_child_watch_add (dialog_pid, dialog_exited, window);
|
||||
}
|
||||
|
||||
void
|
||||
meta_window_check_alive (MetaWindow *window,
|
||||
guint32 timestamp)
|
||||
{
|
||||
meta_display_ping_window (window->display,
|
||||
window,
|
||||
timestamp,
|
||||
delete_ping_reply_func,
|
||||
delete_ping_timeout_func,
|
||||
window);
|
||||
}
|
||||
|
||||
void
|
||||
meta_window_delete (MetaWindow *window,
|
||||
guint32 timestamp)
|
||||
@ -156,13 +168,8 @@ meta_window_delete (MetaWindow *window,
|
||||
}
|
||||
meta_error_trap_pop (window->display);
|
||||
|
||||
meta_display_ping_window (window->display,
|
||||
window,
|
||||
timestamp,
|
||||
delete_ping_reply_func,
|
||||
delete_ping_timeout_func,
|
||||
window);
|
||||
|
||||
meta_window_check_alive (window, timestamp);
|
||||
|
||||
if (window->has_focus)
|
||||
{
|
||||
/* FIXME Clean this up someday
|
||||
|
Reference in New Issue
Block a user