I have a tableview with over 12 different types of cells. I'm using self-sizing and all cells' constraints are set correctly. Everything works perfectly on iPhone simulator, but when it comes to iPad simulator, everything is fine until
- I click a link in the table view and an external browser is displayed.
- I tap on home button and put the app into background.
Once I go back to/reopen the app, the table view scrolls automatically to a random position, and also, as soon as the app goes into background, cellForRowAtIndexPath is called several times(for just the indexes around/including the displaying cells' indexes), looks like the table view scrolls a bit automatically as soon as the app goes into background.
I'm 100% sure tableview.reloadData() is not called anywhere and applicationDidEnterBackground is not implemented either.
Wondering if anyone has encountered the same problem and what could be the potential causes? I tested with XCode 9.3, iPad simulators with iOS version 9.3 and 11.3.
The scenario looks like the following,