|
|
1875c9 |
--- evince-3.8.3/shell/ev-window.c
|
|
|
1875c9 |
+++ evince-3.8.3/shell/ev-window.c
|
|
|
1875c9 |
@@ -228,6 +228,9 @@ struct _EvWindowPrivate {
|
|
|
1875c9 |
#endif
|
|
|
1875c9 |
|
|
|
1875c9 |
guint presentation_mode_inhibit_id;
|
|
|
1875c9 |
+
|
|
|
1875c9 |
+ /* Send to */
|
|
|
1875c9 |
+ gboolean has_mailto_handler;
|
|
|
1875c9 |
};
|
|
|
1875c9 |
|
|
|
1875c9 |
#define EV_WINDOW_GET_PRIVATE(object) \
|
|
|
1875c9 |
@@ -456,7 +459,8 @@ ev_window_setup_action_sensitivity (EvWi
|
|
|
1875c9 |
ev_window_set_action_sensitive (ev_window, "FilePrint", has_pages && ok_to_print);
|
|
|
1875c9 |
ev_window_set_action_sensitive (ev_window, "FileProperties", has_document && has_properties);
|
|
|
1875c9 |
ev_window_set_action_sensitive (ev_window, "FileOpenContainingFolder", has_document);
|
|
|
1875c9 |
- ev_window_set_action_sensitive (ev_window, "FileSendTo", has_document);
|
|
|
1875c9 |
+ ev_window_set_action_sensitive (ev_window, "FileSendTo",
|
|
|
1875c9 |
+ has_document && ev_window->priv->has_mailto_handler);
|
|
|
1875c9 |
ev_window_set_action_sensitive (ev_window, "ViewPresentation", has_document);
|
|
|
1875c9 |
|
|
|
1875c9 |
/* Edit menu */
|
|
|
1875c9 |
@@ -7025,6 +7029,7 @@ ev_window_init (EvWindow *ev_window)
|
|
|
1875c9 |
GDBusConnection *connection;
|
|
|
1875c9 |
static gint window_id = 0;
|
|
|
1875c9 |
#endif
|
|
|
1875c9 |
+ GAppInfo *app_info;
|
|
|
1875c9 |
|
|
|
1875c9 |
g_signal_connect (ev_window, "configure_event",
|
|
|
1875c9 |
G_CALLBACK (window_configure_event_cb), NULL);
|
|
|
1875c9 |
@@ -7075,6 +7080,10 @@ ev_window_init (EvWindow *ev_window)
|
|
|
1875c9 |
G_CALLBACK (activate_link_cb),
|
|
|
1875c9 |
ev_window);
|
|
|
1875c9 |
|
|
|
1875c9 |
+ app_info = g_app_info_get_default_for_uri_scheme ("mailto");
|
|
|
1875c9 |
+ ev_window->priv->has_mailto_handler = app_info != NULL;
|
|
|
1875c9 |
+ g_clear_object (&app_info);
|
|
|
1875c9 |
+
|
|
|
1875c9 |
ev_window->priv->main_box = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
|
|
|
1875c9 |
gtk_container_add (GTK_CONTAINER (ev_window), ev_window->priv->main_box);
|
|
|
1875c9 |
gtk_widget_show (ev_window->priv->main_box);
|