In what situations should I put my code inside the -beginUpdates -endUpdates block and when is it optional?

I am trying to figure out that -beginUpdates and -endUpdates are actually good.

Adding and removing lines should go inside this. But what else? When should I do this? And when is it a good idea, even if I don't need it?

+2


a source to share


1 answer


From the docs for UITableView isUpdates:

Begin a series of method calls that insert, delete, select, or delete receiver rows and sections.

and



Call this method if you want subsequent insertions, deletions and selection operations ... animated at the same time

For me, this exactly answers your question.

+4


a source







All Articles