[gnome-terminal/gnome-3-6] Use correct help: URI for help>contents
- From: Robert Ancell <rancell src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-terminal/gnome-3-6] Use correct help: URI for help>contents
- Date: Sun, 19 Aug 2012 23:21:12 +0000 (UTC)
commit bfe78f78bbca6fbdc7f25b39307a1f852e7cb016
Author: Robert Ancell <robert ancell canonical com>
Date: Mon Aug 20 11:04:21 2012 +1200
Use correct help: URI for help>contents
src/terminal-util.c | 33 +++------------------------------
1 files changed, 3 insertions(+), 30 deletions(-)
---
diff --git a/src/terminal-util.c b/src/terminal-util.c
index 2c24a9a..d6edee0 100644
--- a/src/terminal-util.c
+++ b/src/terminal-util.c
@@ -146,38 +146,12 @@ terminal_util_show_help (const char *topic,
GtkWindow *parent)
{
GError *error = NULL;
- const char *lang;
- char *uri = NULL, *url;
- guint i;
-
- const char * const * langs = g_get_language_names ();
- for (i = 0; langs[i]; i++) {
- lang = langs[i];
- if (strchr (lang, '.')) {
- continue;
- }
-
- uri = g_build_filename (TERM_HELPDIR,
- "gnome-terminal", /* DOC_MODULE */
- lang,
- "gnome-terminal.xml",
- NULL);
-
- if (g_file_test (uri, G_FILE_TEST_EXISTS)) {
- break;
- }
-
- g_free (uri);
- uri = NULL;
- }
-
- if (!uri)
- return;
+ char *url;
if (topic) {
- url = g_strdup_printf ("help:%s/%s", uri, topic);
+ url = g_strdup ("help:gnome-terminal"); /* DOC_MODULE */
} else {
- url = g_strdup_printf ("help:%s", uri);
+ url = g_strdup_printf ("help:gnome-terminal/%s", topic); /* DOC_MODULE */
}
if (!open_url (GTK_WINDOW (parent), url, gtk_get_current_event_time (), &error))
@@ -187,7 +161,6 @@ terminal_util_show_help (const char *topic,
g_error_free (error);
}
- g_free (uri);
g_free (url);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]