Problem with scroll in tableview

Hello everyone, I just found another problem with the tableview.

Recently I had problems with “deleteRow” in this thread: http://forums.coronalabs.com/topic/34014-problem-deleting-rows-in-tableview/. Corona has confirmed to me that this is a bug and they will try to solve it.

Currently working with build 2013.1094 and although I think this is a bug, I expose my problem to know your opinion. 

this is my little program code:

[lua]

– Import the widget library
local widget = require( “widget” )
local list
local addButton
local listRows = {} – my new table

– Handle row rendering
local function onRowRender( event )
   local row = event.row

   local rowTitle = display.newText( row, "List item " … row.index, 0, 0, native.systemFontBold, 16 )
   rowTitle.x = row.x - ( row.contentWidth * 0.5 ) + ( rowTitle.contentWidth * 0.5 )
   rowTitle.y = row.contentHeight * 0.5
   rowTitle:setTextColor( 0, 0, 0 )

   table.insert(listRows, row.index) – Add the row.index to my table
end

– Handle row touch events
local function onRowTouch( event )
   local phase = event.phase
   local row = event.row
   local found

   if “release” == phase then
      found = table.indexOf(listRows, row.index)
      table.remove(listRows, found) – Delete the row from my table
      list:deleteRow(row.index)
   end
end

– Create a tableView
list = widget.newTableView
   {
   top = 38,
   width = 320, 
   height = 448,
   maskFile = “mask-320x448.png”,
   onRowRender = onRowRender,
   onRowTouch = onRowTouch,
   }

– insert rows into list (tableView widget)
for i = 1, 3 do
   list:insertRow{
      height = 72,
   }
end

local function addRow(event)
   if event.phase == “ended” then
      list:insertRow{
         height = 72,
      }
   end
end

– Create a button for insert new rows
addButton = widget.newButton{
   left = 25,
   top = 5,
   width = 100,
   height = 30,
   label = “Add”,
   onEvent = addRow,
}
[/lua]

The steps to reproduce the problem are:

  1. I scroll up until 3 rows hidden there at the beginning and when I release my finger reappear the three firsts rows.

  2. I press the button to add a new row and then instead of inserting the row # 4, it inserted row 6, 7 or 8 and the draw on the second row.

I hope your help

thanks and regards

good weekend

Thanks for posting.  I just upgraded from the 1086 to 1094 daily build and some bugs also appeared in my tableview related to scrolling.  

I have a tableView that shows the facebook friends list in which each row has the friends photo and friends name. When I scroll the list down and then scroll back up to photos in each row are gone…  I also noticed that when a row is gone of the table (when scroll down), when it row returns it is coming with a stroke line.

Summarizing, I am going back to the 1086 version…

Thanks for posting.  I just upgraded from the 1086 to 1094 daily build and some bugs also appeared in my tableview related to scrolling.  

I have a tableView that shows the facebook friends list in which each row has the friends photo and friends name. When I scroll the list down and then scroll back up to photos in each row are gone…  I also noticed that when a row is gone of the table (when scroll down), when it row returns it is coming with a stroke line.

Summarizing, I am going back to the 1086 version…