diff options
author | Christopher James Lahey <clahey@helixcode.com> | 2000-05-08 04:49:02 +0800 |
---|---|---|
committer | Chris Lahey <clahey@src.gnome.org> | 2000-05-08 04:49:02 +0800 |
commit | 56f9196ac4e30fd0f5e0bd79bab0dcfc9856c8ff (patch) | |
tree | 1b90f791be6fcb52dc21e44c44b45099317df91d /widgets/table/e-table-subset-variable.c | |
parent | 271cb81264219225420332375135c74857e035e7 (diff) | |
download | gsoc2013-evolution-56f9196ac4e30fd0f5e0bd79bab0dcfc9856c8ff.tar gsoc2013-evolution-56f9196ac4e30fd0f5e0bd79bab0dcfc9856c8ff.tar.gz gsoc2013-evolution-56f9196ac4e30fd0f5e0bd79bab0dcfc9856c8ff.tar.bz2 gsoc2013-evolution-56f9196ac4e30fd0f5e0bd79bab0dcfc9856c8ff.tar.lz gsoc2013-evolution-56f9196ac4e30fd0f5e0bd79bab0dcfc9856c8ff.tar.xz gsoc2013-evolution-56f9196ac4e30fd0f5e0bd79bab0dcfc9856c8ff.tar.zst gsoc2013-evolution-56f9196ac4e30fd0f5e0bd79bab0dcfc9856c8ff.zip |
Handle row_inserted and row_deleted signals properly.
2000-05-07 Christopher James Lahey <clahey@helixcode.com>
* e-table-item.c, e-table-item.h, e-table.c, e-table.h: Handle
row_inserted and row_deleted signals properly.
* e-table-model.c, e-table-model.h: Created the row_inserted and
row_deleted signals.
* e-table-sorted-variable.c, e-table-subset-variable.c: Emit the
row_inserted and row_deleted signals as appropriate.
svn path=/trunk/; revision=2879
Diffstat (limited to 'widgets/table/e-table-subset-variable.c')
-rw-r--r-- | widgets/table/e-table-subset-variable.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/widgets/table/e-table-subset-variable.c b/widgets/table/e-table-subset-variable.c index bd96d5360c..c42d53842b 100644 --- a/widgets/table/e-table-subset-variable.c +++ b/widgets/table/e-table-subset-variable.c @@ -28,14 +28,19 @@ etssv_add (ETableSubsetVariable *etssv, { ETableModel *etm = E_TABLE_MODEL(etssv); ETableSubset *etss = E_TABLE_SUBSET(etssv); + int i; if (etss->n_map + 1 > etssv->n_vals_allocated){ etss->map_table = g_realloc (etss->map_table, (etssv->n_vals_allocated + INCREMENT_AMOUNT) * sizeof(int)); etssv->n_vals_allocated += INCREMENT_AMOUNT; } + if (row < e_table_model_row_count(etss->source) - 1) + for ( i = 0; i < etss->n_map; i++ ) + if (etss->map_table[i] >= row) + etss->map_table[i] ++; etss->map_table[etss->n_map++] = row; if (!etm->frozen) - e_table_model_changed (etm); + e_table_model_row_inserted (etm, etss->n_map - 1); } static void |