From f73b224daedff8d1f63e35c62a0085a4927221f2 Mon Sep 17 00:00:00 2001 From: Yeongjong Lee Date: Fri, 6 Sep 2019 09:20:13 +0200 Subject: [PATCH] efl_ui_table: update recalc boolean in child delete callback Test Plan: 1. elementary_test -to 'efl.ui.table (linear api)' 2. Click `Append` button 3 times. 3. Click `appended 6` button to delete 4. Click `Append` button. 5. Check that `appended 7` button position (1,1). Reviewers: segfaultxavi Reviewed By: segfaultxavi Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D9856 --- src/lib/elementary/efl_ui_table.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/lib/elementary/efl_ui_table.c b/src/lib/elementary/efl_ui_table.c index 6412b07..13b3c4b 100644 --- a/src/lib/elementary/efl_ui_table.c +++ b/src/lib/elementary/efl_ui_table.c @@ -58,6 +58,14 @@ _on_child_del(void *data, const Efl_Event *event) gi = _efl_ui_table_item_date_get(table, pd, event->object); if (!gi) return; + if ((gi->col == pd->last_col) && (gi->row == pd->last_row)) + pd->linear_recalc = EINA_TRUE; + + if (gi->col + gi->col_span >= pd->cols) + pd->cols_recalc = EINA_TRUE; + if (gi->row + gi->row_span >= pd->rows) + pd->rows_recalc = EINA_TRUE; + pd->items = (Table_Item *) eina_inlist_remove(EINA_INLIST_GET(pd->items), EINA_INLIST_GET(gi)); free(gi); -- 2.7.4