Permalink
Browse files

[fix] CTable: missing calls to dom_show_row and dom_show_cell

  • Loading branch information...
1 parent 2f4a6d9 commit 38529e092195b278b0fbbcb21a66603fb3d39c71 Mathieu Baudet committed Nov 28, 2011
Showing with 6 additions and 3 deletions.
  1. +6 −3 stdlib/components/table/table.opa
@@ -522,10 +522,12 @@ CTable = {{
for_iter(0, col_table_size-1)(i ->
match BMap.get(i, state.col_map) with
| {some=col} ->
+ cell_id = gen_cell_id(table_id, config, row, col, simple)
if ((i >= left) && (i <= right))
- then widget_value(simple, table_id, config, (row,col), channel, {request=callbacks.request_value})
+ then
+ do widget_value(simple, table_id, config, (row,col), channel, {request=callbacks.request_value})
+ dom_show_cell(0, #{cell_id},simple)
else
- cell_id = gen_cell_id(table_id, config, row, col, simple)
dom_hide_cell(0, #{cell_id},simple)
| {none} -> void
)
@@ -786,15 +788,16 @@ CTable = {{
do Dom.transform([{Dom.select_raw("#{table_id}_table tbody")} +<- row_html])
// Check if the added row is in the display scope
(bottom,nb_rows) =
+ row_id = gen_row_id(table_id, config, row)
if nb_rows < row_page_size && not(is_filtered(row))
then
// Show the added row
do request_values(row)
+ do dom_show_row(0, #{row_id})
// a new row added to the display -> bottom++
(bottom + 1, nb_rows + 1)
else
// hide the row
- row_id = gen_row_id(table_id, config, row)
do dom_hide_row(0, #{row_id})
// bottom unchanged
(bottom, nb_rows)

0 comments on commit 38529e0

Please sign in to comment.