aboutsummaryrefslogtreecommitdiffstats
path: root/addressbook/gui/component/select-names/e-select-names-model.c
diff options
context:
space:
mode:
authorChristopher James Lahey <clahey@helixcode.com>2000-07-08 02:37:43 +0800
committerChris Lahey <clahey@src.gnome.org>2000-07-08 02:37:43 +0800
commitcf61f7c4dd6f445be551bea4b55e7902edf4a816 (patch)
tree318ef66d98dbbd186310f71fefcc35cbd9812045 /addressbook/gui/component/select-names/e-select-names-model.c
parentfc43959180e0ab748ba68fa4834e6913f2aba74e (diff)
downloadgsoc2013-evolution-cf61f7c4dd6f445be551bea4b55e7902edf4a816.tar
gsoc2013-evolution-cf61f7c4dd6f445be551bea4b55e7902edf4a816.tar.gz
gsoc2013-evolution-cf61f7c4dd6f445be551bea4b55e7902edf4a816.tar.bz2
gsoc2013-evolution-cf61f7c4dd6f445be551bea4b55e7902edf4a816.tar.lz
gsoc2013-evolution-cf61f7c4dd6f445be551bea4b55e7902edf4a816.tar.xz
gsoc2013-evolution-cf61f7c4dd6f445be551bea4b55e7902edf4a816.tar.zst
gsoc2013-evolution-cf61f7c4dd6f445be551bea4b55e7902edf4a816.zip
Make the entry widgets we create editable.
2000-07-07 Christopher James Lahey <clahey@helixcode.com> * gui/component/select-names/e-select-names-manager.c: Make the entry widgets we create editable. * gui/component/select-names/e-select-names-model.c: Use e_strsplit instead of g_strsplit. Fixed an off by 1 error. * gui/component/select-names/e-select-names-table-model.c: When the model changes, send a model changed signal. * gui/component/select-names/e-select-names-text-model.c: Made changing this work correctly if it's empty. Made change signals propagate properly. Is a bit better about freeing iterators when done. * gui/component/select-names/e-select-names.c: Made the finished lists be in order instead of being sorted. svn path=/trunk/; revision=3955
Diffstat (limited to 'addressbook/gui/component/select-names/e-select-names-model.c')
-rw-r--r--addressbook/gui/component/select-names/e-select-names-model.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/addressbook/gui/component/select-names/e-select-names-model.c b/addressbook/gui/component/select-names/e-select-names-model.c
index 5bf9562646..98745523a1 100644
--- a/addressbook/gui/component/select-names/e-select-names-model.c
+++ b/addressbook/gui/component/select-names/e-select-names-model.c
@@ -13,6 +13,7 @@
#include <gtk/gtk.h>
#include "e-select-names-model.h"
+#include "e-util/e-util.h"
enum {
E_SELECT_NAMES_MODEL_CHANGED,
@@ -212,7 +213,7 @@ e_select_names_model_insert (ESelectNamesModel *model,
int index,
char *data)
{
- gchar **strings = g_strsplit(data, ",", -1);
+ gchar **strings = e_strsplit(data, ",", -1);
int i;
if (iterator == NULL) {
ESelectNamesModelData new = {E_SELECT_NAMES_MODEL_DATA_TYPE_STRING_ADDRESS, NULL, ""};
@@ -228,7 +229,7 @@ e_select_names_model_insert (ESelectNamesModel *model,
g_free(node->string);
node->string = temp;
}
- for (i = 0; strings[i]; i++) {
+ for (i = 1; strings[i]; i++) {
ESelectNamesModelData *node = (void *) e_iterator_get(iterator);
gchar *temp = g_strdup_printf("%.*s", index, node->string);
gchar *temp2 = g_strdup_printf("%s%s", strings[0], node->string + index);