TableView deleting row contents after scrolling them off display revisited!

Ok so last time we established that this was expected behaviour for the tabelview to clean up the rows and nuke display objects in those rows. 

So then my new question is how do I detect when this is happening so that I can stop any transitions occuring on items in those rows.

Currently I get an exception and a full on app crash when corona decides to delete a sprite that I have in a row and am transitioning it’s alpha in a continuousLoop (pulse effect).

If you want to reproduce the bug just attach a sprite to a row. transition the alpha on the sprite and scroll the row off screen until the tableview decides to clean it up and hey presto a full on crash.

You can add a finalize function to your object and have it cancel the transition before it’s removed.  See:

http://docs.coronalabs.com/api/event/finalize/index.html

You can add a finalize function to your object and have it cancel the transition before it’s removed.  See:

http://docs.coronalabs.com/api/event/finalize/index.html