aboutsummaryrefslogtreecommitdiffstats
path: root/e-util
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@src.gnome.org>2009-01-12 12:12:01 +0800
committerMatthew Barnes <mbarnes@src.gnome.org>2009-01-12 12:12:01 +0800
commitc7d3c9f95609123035ebaa267f9d2e6ecfa8c2e8 (patch)
tree246bdb714e24e1b0c9a8ce4a3e45a46b230316de /e-util
parentf8b33bc4ebe9dd8043674141b5fe4660efaa99e8 (diff)
downloadgsoc2013-evolution-c7d3c9f95609123035ebaa267f9d2e6ecfa8c2e8.tar.gz
gsoc2013-evolution-c7d3c9f95609123035ebaa267f9d2e6ecfa8c2e8.tar.zst
gsoc2013-evolution-c7d3c9f95609123035ebaa267f9d2e6ecfa8c2e8.zip
Merge revisions 36866:37046 from trunk.
svn path=/branches/kill-bonobo/; revision=37050
Diffstat (limited to 'e-util')
-rw-r--r--e-util/ChangeLog32
-rw-r--r--e-util/e-config.c15
-rw-r--r--e-util/e-dialog-utils.c2
-rw-r--r--e-util/e-util-labels.c4
4 files changed, 47 insertions, 6 deletions
diff --git a/e-util/ChangeLog b/e-util/ChangeLog
index 2cc9357c29..365589f575 100644
--- a/e-util/ChangeLog
+++ b/e-util/ChangeLog
@@ -1,3 +1,35 @@
+2009-01-11 Matthew Barnes <mbarnes@redhat.com>
+
+ * e-error.c (ee_response):
+ Call e_display_help() instead of gnome_url_show().
+
+ * e-util.c (e_show_uri):
+ New convenience function calls gtk_show_uri() and displays an
+ error dialog if the URI cannot be shown.
+
+2009-01-10 Matthew Barnes <mbarnes@redhat.com>
+
+ * e-dialog-utils.c:
+ Remove unneeded #include <libgnome/gnome-util.h>.
+
+2009-01-10 Matthew Barnes <mbarnes@redhat.com>
+
+ * e-util.c (e_display_help):
+ Now that we require GTK+ 2.14, use gtk_show_uri() instead of
+ gnome_help_display().
+
+2009-01-01 Matthew Barnes <mbarnes@redhat.com>
+
+ * e-config.c (ec_rebuild):
+ Use the translated the EConfigItem label when building the UI.
+
+2008-12-22 Matthew Barnes <mbarnes@redhat.com>
+
+ ** Fixes bug #564860
+
+ * e-util-label.c (e_util_labels_parse):
+ Don't crash on malformed label strings.
+
2008-12-10 Matthew Barnes <mbarnes@redhat.com>
** Fixes part of bug #563250
diff --git a/e-util/e-config.c b/e-util/e-config.c
index 03a553feb2..4530d7a78b 100644
--- a/e-util/e-config.c
+++ b/e-util/e-config.c
@@ -28,6 +28,7 @@
#include <stdlib.h>
#include <gtk/gtk.h>
+#include <glib/gi18n.h>
#include <libgnomeui/gnome-druid.h>
#include <libgnomeui/gnome-druid-page-standard.h>
@@ -422,10 +423,14 @@ ec_rebuild(EConfig *emp)
for (wn = (struct _widget_node *)p->widgets.head;wn->next;wn=wn->next) {
struct _EConfigItem *item = wn->item;
+ const gchar *translated_label = NULL;
GtkWidget *w;
d(printf(" '%s'\n", item->path));
+ if (item->label != NULL)
+ translated_label = gettext (item->label);
+
/* If the last section doesn't contain anything, hide it */
if (sectionnode != NULL
&& sectionnode->frame != NULL
@@ -524,7 +529,7 @@ ec_rebuild(EConfig *emp)
} else {
page = gnome_druid_page_edge_new(item->type == E_CONFIG_PAGE_START?GNOME_EDGE_START:GNOME_EDGE_FINISH);
gtk_widget_show(page);
- gnome_druid_page_edge_set_title((GnomeDruidPageEdge *)page, item->label);
+ gnome_druid_page_edge_set_title((GnomeDruidPageEdge *)page, translated_label);
gnome_druid_insert_page((GnomeDruid *)druid, pagenode?(GnomeDruidPage *)pagenode->frame:NULL, (GnomeDruidPage *)page);
}
if (item->type == E_CONFIG_PAGE_FINISH) {
@@ -579,13 +584,13 @@ ec_rebuild(EConfig *emp)
if (emp->type == E_CONFIG_DRUID) {
w = gnome_druid_page_standard_new();
gtk_widget_show(w);
- gnome_druid_page_standard_set_title((GnomeDruidPageStandard *)w, item->label);
+ gnome_druid_page_standard_set_title((GnomeDruidPageStandard *)w, translated_label);
gnome_druid_insert_page((GnomeDruid *)druid, pagenode?(GnomeDruidPage *)pagenode->frame:NULL, (GnomeDruidPage *)w);
wn->frame = w;
page = ((GnomeDruidPageStandard *)w)->vbox;
connect = TRUE;
} else {
- w = gtk_label_new_with_mnemonic (item->label);
+ w = gtk_label_new_with_mnemonic (translated_label);
gtk_widget_show(w);
page = gtk_vbox_new(FALSE, 12);
gtk_container_set_border_width((GtkContainer *)page, 12);
@@ -653,8 +658,8 @@ ec_rebuild(EConfig *emp)
wn->frame = NULL;
}
- if (item->label) {
- char *txt = g_strdup_printf("<span weight=\"bold\">%s</span>", item->label);
+ if (translated_label != NULL) {
+ char *txt = g_strdup_printf("<span weight=\"bold\">%s</span>", translated_label);
label = g_object_new(gtk_label_get_type(),
"label", txt,
diff --git a/e-util/e-dialog-utils.c b/e-util/e-dialog-utils.c
index a97d2c936f..99b5ad9b61 100644
--- a/e-util/e-dialog-utils.c
+++ b/e-util/e-dialog-utils.c
@@ -27,6 +27,7 @@
#include "e-dialog-utils.h"
+#include <errno.h>
#include <unistd.h>
#include <glib/gstdio.h>
@@ -36,7 +37,6 @@
#include <gconf/gconf-client.h>
#include <glib/gi18n.h>
-#include <libgnome/gnome-util.h>
#include "e-util/e-util.h"
#include "e-util/e-error.h"
diff --git a/e-util/e-util-labels.c b/e-util/e-util-labels.c
index 88fff080b7..85984da59c 100644
--- a/e-util/e-util-labels.c
+++ b/e-util/e-util-labels.c
@@ -71,6 +71,10 @@ e_util_labels_parse (GConfClient *client)
char *color, *name, *tag;
name = buf = list->data;
color = strrchr (buf, ':');
+ if (color == NULL) {
+ g_free (buf);
+ continue;
+ }
*color++ = '\0';
tag = strchr (color, '|');