aboutsummaryrefslogtreecommitdiffstats
path: root/composer/e-msg-composer-address-entry.c
diff options
context:
space:
mode:
Diffstat (limited to 'composer/e-msg-composer-address-entry.c')
-rw-r--r--composer/e-msg-composer-address-entry.c16
1 files changed, 12 insertions, 4 deletions
diff --git a/composer/e-msg-composer-address-entry.c b/composer/e-msg-composer-address-entry.c
index ce946d203e..63b338b905 100644
--- a/composer/e-msg-composer-address-entry.c
+++ b/composer/e-msg-composer-address-entry.c
@@ -26,7 +26,7 @@
cooler. */
#include <gnome.h>
-
+#include <e-util/e-unicode.h>
#include "e-msg-composer-address-entry.h"
@@ -98,11 +98,11 @@ GList *
e_msg_composer_address_entry_get_addresses (EMsgComposerAddressEntry *entry)
{
GList *list;
- const gchar *s;
const gchar *p, *oldp;
+ gchar *s;
gboolean in_quotes;
- s = gtk_entry_get_text (GTK_ENTRY (entry));
+ s = e_utf8_gtk_entry_get_text (GTK_ENTRY (entry));
in_quotes = FALSE;
list = NULL;
@@ -110,6 +110,8 @@ e_msg_composer_address_entry_get_addresses (EMsgComposerAddressEntry *entry)
p = s;
oldp = s;
+ /* This should work with UTF-8, although it uses simple pointer increment */
+
while (1) {
if (*p == '"') {
in_quotes = ! in_quotes;
@@ -138,6 +140,8 @@ e_msg_composer_address_entry_get_addresses (EMsgComposerAddressEntry *entry)
}
}
+ g_free (s);
+
return g_list_reverse (list);
}
@@ -170,6 +174,10 @@ e_msg_composer_address_entry_set_list (EMsgComposerAddressEntry *entry,
g_string_append (string, p->data);
}
- gtk_entry_set_text (GTK_ENTRY (entry), string->str);
+ e_utf8_gtk_entry_set_text (GTK_ENTRY (entry), string->str);
g_string_free (string, TRUE);
}
+
+
+
+