aboutsummaryrefslogtreecommitdiffstats
path: root/widgets
diff options
context:
space:
mode:
authorChristopher James Lahey <clahey@ximian.com>2001-09-08 02:53:35 +0800
committerChris Lahey <clahey@src.gnome.org>2001-09-08 02:53:35 +0800
commit3f2384a8729d05203f0ce4d4dc9b3de236f9c18c (patch)
tree5acee6fe0adf2384dee15a0ad729c598b6b5027a /widgets
parente0e4a236e5deb2c1009dfc62ed0e78207b542767 (diff)
downloadgsoc2013-evolution-3f2384a8729d05203f0ce4d4dc9b3de236f9c18c.tar
gsoc2013-evolution-3f2384a8729d05203f0ce4d4dc9b3de236f9c18c.tar.gz
gsoc2013-evolution-3f2384a8729d05203f0ce4d4dc9b3de236f9c18c.tar.bz2
gsoc2013-evolution-3f2384a8729d05203f0ce4d4dc9b3de236f9c18c.tar.lz
gsoc2013-evolution-3f2384a8729d05203f0ce4d4dc9b3de236f9c18c.tar.xz
gsoc2013-evolution-3f2384a8729d05203f0ce4d4dc9b3de236f9c18c.tar.zst
gsoc2013-evolution-3f2384a8729d05203f0ce4d4dc9b3de236f9c18c.zip
Added this function.
2001-09-07 Christopher James Lahey <clahey@ximian.com> * e-table-without.c, e-table-without.h (e_table_without_show_all): Added this function. svn path=/trunk/; revision=12677
Diffstat (limited to 'widgets')
-rw-r--r--widgets/table/e-table-without.c31
-rw-r--r--widgets/table/e-table-without.h1
2 files changed, 30 insertions, 2 deletions
diff --git a/widgets/table/e-table-without.c b/widgets/table/e-table-without.c
index db05b072d1..e14b8aca8b 100644
--- a/widgets/table/e-table-without.c
+++ b/widgets/table/e-table-without.c
@@ -309,8 +309,9 @@ void e_table_without_hide_adopt (ETableWithout *etw,
}
}
-void e_table_without_show (ETableWithout *etw,
- void *key)
+void
+e_table_without_show (ETableWithout *etw,
+ void *key)
{
int i; /* Model row */
ETableSubset *etss = E_TABLE_SUBSET (etw);
@@ -332,3 +333,29 @@ void e_table_without_show (ETableWithout *etw,
g_hash_table_remove (etw->priv->hash, key);
}
}
+
+void
+e_table_without_show_all (ETableWithout *etw)
+{
+ int i; /* Model row */
+ int row_count;
+ ETableSubset *etss = E_TABLE_SUBSET (etw);
+
+ if (etw->priv->hash) {
+ g_hash_table_foreach (etw->priv->hash, delete_hash_element, etw);
+ g_hash_table_destroy (etw->priv->hash);
+ etw->priv->hash = NULL;
+ }
+ etw->priv->hash = g_hash_table_new (etw->priv->hash_func, etw->priv->compare_func);
+
+ g_free (etss->map_table);
+ row_count = e_table_model_row_count (E_TABLE_MODEL(etw));
+ etss->map_table = g_new (int, row_count);
+
+ for (i = 0; i < row_count; i++) {
+ etss->map_table[i++] = i;
+ }
+ etss->n_map = i;
+
+ e_table_model_changed (E_TABLE_MODEL (etw));
+}
diff --git a/widgets/table/e-table-without.h b/widgets/table/e-table-without.h
index 62dd718f28..9916719eb8 100644
--- a/widgets/table/e-table-without.h
+++ b/widgets/table/e-table-without.h
@@ -58,6 +58,7 @@ void e_table_without_hide_adopt (ETableWithout *etw,
void *key);
void e_table_without_show (ETableWithout *etw,
void *key);
+void e_table_without_show_all (ETableWithout *etw);
#ifdef __cplusplus
}
#endif /* __cplusplus */