Contents

presentModalViewController:animated:

Presents a modal view managed by the given view controller to the user.

Declaration

- (void) presentModalViewController:(UIViewController *) modalViewController animated:(BOOL) animated;

Parameters

  • modalViewController:

    The view controller that manages the modal view.

  • animated:

    If True, animates the view as it’s presented; otherwise, does not.

Discussion

On iPhone and iPod touch devices, the view of modalViewController is always presented full screen. On iPad, the presentation depends on the value in the modalPresentationStyle property.

Sets the modalViewController property to the specified view controller. Resizes its view and attaches it to the view hierarchy. The view is animated according to the transition style specified in the modalTransitionStyle property of the controller in the modalViewController parameter.

See Also

Deprecated methods