aboutsummaryrefslogtreecommitdiffstats
path: root/e-util/e-datetime-format.c
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2010-10-21 03:06:38 +0800
committerMatthew Barnes <mbarnes@redhat.com>2010-10-21 03:08:16 +0800
commit8da37ea812d5b784dade3dc0f05df54fdc60fc7a (patch)
tree04bf6d75a584f2f8af8c4b061e38bf8220a0bf15 /e-util/e-datetime-format.c
parent4142c97c7b59de8d859a217d7b76667b339e33c0 (diff)
downloadgsoc2013-evolution-8da37ea812d5b784dade3dc0f05df54fdc60fc7a.tar.gz
gsoc2013-evolution-8da37ea812d5b784dade3dc0f05df54fdc60fc7a.tar.zst
gsoc2013-evolution-8da37ea812d5b784dade3dc0f05df54fdc60fc7a.zip
Bug 632641 - Handle combo box text API going away
Diffstat (limited to 'e-util/e-datetime-format.c')
-rw-r--r--e-util/e-datetime-format.c15
1 files changed, 11 insertions, 4 deletions
diff --git a/e-util/e-datetime-format.c b/e-util/e-datetime-format.c
index 11e7fb2707..05630d2ec7 100644
--- a/e-util/e-datetime-format.c
+++ b/e-util/e-datetime-format.c
@@ -25,6 +25,9 @@
#include "e-datetime-format.h"
#include "e-util.h"
+/* backward-compatibility cruft */
+#include "e-util/gtk-compat.h"
+
#define KEYS_FILENAME "datetime-formats.ini"
#define KEYS_GROUPNAME "formats"
@@ -358,16 +361,19 @@ fill_combo_formats (GtkWidget *combo, const gchar *key, DTFormatKind kind)
for (i = 0; items[i]; i++) {
if (i == 0) {
- gtk_combo_box_append_text ((GtkComboBox *) combo, _(items[i]));
+ gtk_combo_box_text_append_text (
+ GTK_COMBO_BOX_TEXT (combo), _(items[i]));
} else {
- gtk_combo_box_append_text ((GtkComboBox *) combo, items[i]);
+ gtk_combo_box_text_append_text (
+ GTK_COMBO_BOX_TEXT (combo), items[i]);
if (!idx && fmt && g_str_equal (fmt, items[i]))
idx = i;
}
}
if (idx == 0 && fmt && !g_str_equal (fmt, get_default_format (kind, key))) {
- gtk_combo_box_append_text ((GtkComboBox *) combo, fmt);
+ gtk_combo_box_text_append_text (
+ GTK_COMBO_BOX_TEXT (combo), fmt);
idx = i;
}
@@ -421,7 +427,8 @@ format_combo_changed_cb (GtkWidget *combo, gpointer user_data)
} else {
gchar *text;
- text = gtk_combo_box_get_active_text (GTK_COMBO_BOX (combo));
+ text = gtk_combo_box_text_get_active_text (
+ GTK_COMBO_BOX_TEXT (combo));
set_format_internal (key, text, keyfile);
g_free (text);
}