Contents

makeView(element:existingView:)

Returns a view for a view element.

Declaration

optional func makeView(element: TVViewElement, existingView: UIView?) -> UIView?

Parameters

  • element:

    The view element requesting a new view.

  • existingView:

    The current view.

Mentioned in

Return Value

The new view associated with the view element. If the app doesn’t handle the event, you must return nil.

Discussion

When possible, update the view contained in the existingView parameter instead of creating a new view. However, if the existing view is an instance of UICollectionViewCell, you must configure the cell instead of creating a new instance.

See Also

Updating View Information