What is the difference between:
[self.navigationController presentModalViewController:nav animated:YES];
and
[self presentModalViewController:nav animated:YES];
Where self is a subclass of UIViewController.
Along with that, does it matter how I dismiss the modal view? Example:
[self dismissModalViewControllerAnimated:YES];
or
[self.navigationController dismissModalViewControllerAnimated:YES];
If a modalView is presented by self.navigationController
, will it be dismissed if called on self
, and vice versa?
I know that apple recommends using a protocol and delegate in actual implementation, but I am just trying to find out if the behavior "under the hood" is the same or not.
I have been looking around to try and find an answer to this but I haven't found anything yet, so if this is a duplicate I apologize before hand.
Thanks