aboutsummaryrefslogtreecommitdiffstats
path: root/widgets
diff options
context:
space:
mode:
authorChristopher James Lahey <clahey@ximian.com>2002-03-12 07:05:34 +0800
committerChris Lahey <clahey@src.gnome.org>2002-03-12 07:05:34 +0800
commit732d4c40a0b6a276fcd9aa43710c2264b7baaa42 (patch)
tree8215fe94f75f54ab2427cdb5511e1a7fae5564e6 /widgets
parente94b86c4b5d7fa2d431d2dbbca0c29ef5e48a7e6 (diff)
downloadgsoc2013-evolution-732d4c40a0b6a276fcd9aa43710c2264b7baaa42.tar
gsoc2013-evolution-732d4c40a0b6a276fcd9aa43710c2264b7baaa42.tar.gz
gsoc2013-evolution-732d4c40a0b6a276fcd9aa43710c2264b7baaa42.tar.bz2
gsoc2013-evolution-732d4c40a0b6a276fcd9aa43710c2264b7baaa42.tar.lz
gsoc2013-evolution-732d4c40a0b6a276fcd9aa43710c2264b7baaa42.tar.xz
gsoc2013-evolution-732d4c40a0b6a276fcd9aa43710c2264b7baaa42.tar.zst
gsoc2013-evolution-732d4c40a0b6a276fcd9aa43710c2264b7baaa42.zip
Added this function to take a ... list of column data. The expected number
2002-03-11 Christopher James Lahey <clahey@ximian.com> * e-table-memory-store.c (e_table_memory_store_insert_list): Added this function to take a ... list of column data. The expected number of parameters in the ... is the number of columns in the table. svn path=/trunk/; revision=16109
Diffstat (limited to 'widgets')
-rw-r--r--widgets/table/e-table-memory-store.c20
-rw-r--r--widgets/table/e-table-memory-store.h4
2 files changed, 24 insertions, 0 deletions
diff --git a/widgets/table/e-table-memory-store.c b/widgets/table/e-table-memory-store.c
index 5cf59a7033..c54bfb6190 100644
--- a/widgets/table/e-table-memory-store.c
+++ b/widgets/table/e-table-memory-store.c
@@ -332,6 +332,26 @@ e_table_memory_store_insert (ETableMemoryStore *etms, int row, void **store, gpo
}
void
+e_table_memory_store_insert_list (ETableMemoryStore *etms, int row, gpointer data, ...)
+{
+ void **store;
+ va_list args;
+ int i;
+
+ store = g_new (void *, etms->priv->col_count + 1);
+
+ va_start (args, data);
+ for (i = 0; i < etms->priv->col_count; i++) {
+ store[i] = va_arg (args, void *);
+ }
+ va_end (args);
+
+ e_table_memory_store_insert (etms, row, store, data);
+
+ g_free (store);
+}
+
+void
e_table_memory_store_insert_adopt (ETableMemoryStore *etms, int row, void **store, gpointer data)
{
int row_count;
diff --git a/widgets/table/e-table-memory-store.h b/widgets/table/e-table-memory-store.h
index 3a68e6df94..49f37ba201 100644
--- a/widgets/table/e-table-memory-store.h
+++ b/widgets/table/e-table-memory-store.h
@@ -97,6 +97,10 @@ void e_table_memory_store_insert (ETableMemoryStore
int row,
void **store,
gpointer data);
+void e_table_memory_store_insert_list (ETableMemoryStore *etms,
+ int row,
+ gpointer data,
+ ...);
void e_table_memory_store_insert_adopt (ETableMemoryStore *etms,
int row,
void **store,