diff options
Diffstat (limited to 'mate-panel/panel-applet-frame.c')
-rw-r--r-- | mate-panel/panel-applet-frame.c | 18 |
1 files changed, 14 insertions, 4 deletions
diff --git a/mate-panel/panel-applet-frame.c b/mate-panel/panel-applet-frame.c index 5b4b96c9..f795ed1e 100644 --- a/mate-panel/panel-applet-frame.c +++ b/mate-panel/panel-applet-frame.c @@ -31,7 +31,6 @@ #include <gio/gio.h> #include <gdk/gdk.h> -#include <gdk/gdkx.h> #include <libpanel-util/panel-gtk.h> @@ -43,7 +42,9 @@ #include "panel-background.h" #include "panel-lockdown.h" #include "panel-stock-icons.h" +#ifdef HAVE_X11 #include "xstuff.h" +#endif #include "panel-schemas.h" #include "panel-applet-frame.h" @@ -746,8 +747,10 @@ _mate_panel_applet_frame_applet_broken (MatePanelAppletFrame *frame) screen = gtk_widget_get_screen (GTK_WIDGET (frame)); - if (xstuff_is_display_dead ()) +#ifdef HAVE_X11 + if (is_using_x11 () && xstuff_is_display_dead ()) return; +#endif if (frame->priv->iid) { MatePanelAppletInfo *info; @@ -800,8 +803,15 @@ _mate_panel_applet_frame_applet_broken (MatePanelAppletFrame *frame) gtk_widget_show (dialog); - gtk_window_present_with_time (GTK_WINDOW (dialog), - gdk_x11_get_server_time (gtk_widget_get_window (GTK_WIDGET (dialog)))); +#ifdef HAVE_X11 + if (GDK_IS_X11_DISPLAY (gtk_widget_get_display (dialog))) + gtk_window_present_with_time (GTK_WINDOW (dialog), + gdk_x11_get_server_time (gtk_widget_get_window (GTK_WIDGET (dialog)))); + else +#endif + { // Not using X11 + gtk_window_present(GTK_WINDOW (dialog)); + } g_free (dialog_txt); } |