0

So as the title say, I'm looking for a method that will be called when a "modal" UIViewController is about to be displayed -- so I can remove any attached observers -- then a method when the presented "modal" UIViewController is dismissed -- so I can reattach the observers --

In android when dialog is displayed the "fragment's onPause" is called then the "fragment's onResume" is called when the dialog is dismissed. I'm looking for something like that.

I know this can be done with the use of the delegate but If there's a already existing one that I'm not aware of please let me know.

SquareBox
  • 823
  • 1
  • 10
  • 22
  • Take a look at this - [iOS - Android Life Cycle](https://stackoverflow.com/questions/28969032/what-the-equivalent-of-activity-life-cycle-in-ios) – Chris Jul 12 '17 at 04:16
  • @Chris thanks for the quick response, I already tried that and viewWillDisappear is not called when a modal is displayed over. – SquareBox Jul 12 '17 at 04:23

0 Answers0