Inherits from UIViewController
Conforms to UIViewControllerAnimatedTransitioning
Declared in TKCustomPresentationViewController.h
TKCustomPresentationViewController.m

Overview

TKCustomPresentationViewController is view controller setup to make its own custom presentation and dismissal.

Properties

transitionContext

The UIViewControllerContextTransitioning that governs the presentation and dismissal.

@property (nonatomic, strong) id<UIViewControllerContextTransitioning> transitionContext

Declared In

TKCustomPresentationViewController.h

Instance Methods

dismissTransitionAnimation:containerView:toViewController:

Subclass this method to create a custom dismissal transition.

- (void)dismissTransitionAnimation:(id<UIViewControllerContextTransitioning>)transitionContext containerView:(UIView *)containerView toViewController:(UIViewController *)toViewController

Parameters

transitionContext

The UIViewControllerContextTransitioning that governs the presentation.

containerView

The container view to place this view controller’s view.

toViewController

The parent view controller.

Declared In

TKCustomPresentationViewController.h

presentTransitionAnimation:containerView:fromViewController:

Subclass this method to create a custom presentation transition.

- (void)presentTransitionAnimation:(id<UIViewControllerContextTransitioning>)transitionContext containerView:(UIView *)containerView fromViewController:(UIViewController *)fromViewController

Parameters

transitionContext

The UIViewControllerContextTransitioning that governs the presentation.

containerView

The container view to place this view controller’s view.

fromViewController

The parent view controller.

Declared In

TKCustomPresentationViewController.h

transitionDuration:

The duration of the transition.

- (NSTimeInterval)transitionDuration:(id<UIViewControllerContextTransitioning>)transitionContext

Parameters

transitionContext

The UIViewControllerContextTransitioning that governs the presentation.

Return Value

The time of the transition.

Declared In

TKCustomPresentationViewController.h

transitionEnded

Call this method upon completion of the presentation and dismissal animations.

- (void)transitionEnded

Declared In

TKCustomPresentationViewController.h