1

I have a library that must present a modal view. How do I find the top most visible UIViewController to call presentViewController on? My current app has a table view controller, navigation controllers, and other modal views.

The best I could find is this, but this results in unbalanced calls to begin/end appearance transitions for <UIViewController: 0x...> followed by a EXC_BAD_ACCESS. (This was when there was another modal view controller at top.)

Community
  • 1
  • 1
meaning-matters
  • 18,141
  • 8
  • 65
  • 115
  • Have you tried this especially 2nd answer: http://stackoverflow.com/questions/6131205/iphone-how-to-find-topmost-view-controller? Otherwise it might be better just to have your own overlay UIWindow. – Valent Richie May 30 '13 at 13:54

0 Answers0