From be4fa2808c4e1a36c2c9b58c1267a54cdda6e495 Mon Sep 17 00:00:00 2001 From: Wu Xiaotian Date: Fri, 27 Dec 2019 17:13:43 +0800 Subject: enable wayland support --- src/eom-application.c | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) (limited to 'src/eom-application.c') diff --git a/src/eom-application.c b/src/eom-application.c index a46ead7..20d9aca 100644 --- a/src/eom-application.c +++ b/src/eom-application.c @@ -332,24 +332,11 @@ eom_application_get_file_window (EomApplication *application, GFile *file) static void eom_application_show_window (EomWindow *window, gpointer user_data) { - guint32 timestamp = GPOINTER_TO_UINT (user_data); - - /* set the proper interaction time on the window. - * Fall back to roundtripping to the X server when we - * don't have the timestamp, e.g. when launched from - * terminal. We also need to make sure that the window - * has been realized otherwise it will not work. lame. - */ if (!gtk_widget_get_realized (GTK_WIDGET (window))) gtk_widget_realize (GTK_WIDGET (window)); - if (timestamp <= 0) - timestamp = gdk_x11_get_server_time (gtk_widget_get_window (GTK_WIDGET (window))); - - gdk_x11_window_set_user_time (gtk_widget_get_window (GTK_WIDGET (window)), - timestamp); - - gtk_window_present (GTK_WINDOW (window)); + gtk_window_present_with_time (GTK_WINDOW (window), + GPOINTER_TO_UINT (user_data)); } /** -- cgit v1.2.1