]> www.fi.muni.cz Git - evince.git/commitdiff
Use gtk_show_uri() when availale to display help contents.
authorCarlos Garcia Campos <carlosgc@gnome.org>
Sat, 1 Nov 2008 11:25:07 +0000 (11:25 +0000)
committerCarlos Garcia Campos <carlosgc@src.gnome.org>
Sat, 1 Nov 2008 11:25:07 +0000 (11:25 +0000)
2008-11-01  Carlos Garcia Campos  <carlosgc@gnome.org>

* shell/ev-window.c: (ev_window_cmd_help_contents):

Use gtk_show_uri() when availale to display help contents.

svn path=/trunk/; revision=3243

ChangeLog
shell/ev-window.c

index 31b92dd77b505a01b58dcb7990176e1ec161188a..be867033fdf836d53194a00c5ae518ea9994f2c5 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2008-11-01  Carlos Garcia Campos  <carlosgc@gnome.org>
+
+       * shell/ev-window.c: (ev_window_cmd_help_contents):
+
+       Use gtk_show_uri() when availale to display help contents.
+       
 2008-10-31  Carlos Garcia Campos  <carlosgc@gnome.org>
 
        * configure.ac:
index 60ea87c15dbd81983121706f40ea5cbc6d826015..386a28051934ce8f0204c15856087de37b227bb9 100644 (file)
@@ -3318,6 +3318,24 @@ ev_window_cmd_view_autoscroll (GtkAction *action, EvWindow *ev_window)
        ev_view_autoscroll_start (EV_VIEW (ev_window->priv->view));
 }
 
+#if GTK_CHECK_VERSION (2, 14, 0)
+static void
+ev_window_cmd_help_contents (GtkAction *action, EvWindow *ev_window)
+{
+       GError  *error = NULL;
+
+       gtk_show_uri (gtk_window_get_screen (GTK_WINDOW (ev_window)),
+                     "ghelp:evince",
+                     GDK_CURRENT_TIME,
+                     &error);
+       if (error) {
+               ev_window_error_message (GTK_WINDOW (ev_window),
+                                        _("There was an error displaying help"),
+                                        error);
+               g_error_free (error);
+       }
+}
+#else /* !GTK_CHECK_VERSION (2, 14, 0) */
 static void
 ev_window_cmd_help_contents (GtkAction *action, EvWindow *ev_window)
 {
@@ -3366,6 +3384,7 @@ ev_window_cmd_help_contents (GtkAction *action, EvWindow *ev_window)
        }
        g_free (command);
 }
+#endif /* GTK_CHECK_VERSION (2, 14, 0) */
 
 static void
 ev_window_cmd_leave_fullscreen (GtkAction *action, EvWindow *window)