Contents

tableView(_:didUpdateFocusIn:with:)

Tells the delegate that a focus update specified by the context has just occurred.

Declaration

optional func tableView(_ tableView: UITableView, didUpdateFocusIn context: UITableViewFocusUpdateContext, with coordinator: UIFocusAnimationCoordinator)

Parameters

  • tableView:

    A table view informing the delegate about the new focus.

  • context:

    An instance of the Uifocusupdatecontext class, containing metadata for the focus related update.

  • coordinator:

    An instance of the Uifocusupdatecontext class, containing metadata for the focus related update.

Discussion

This functionality of this delegate method is equivalent to overriding UITableView class’s implementation of tableView(_:didUpdateFocusIn:with:). This delegate method provides additional UITableView-related information in its context parameter, such as the index paths for the previously and next focused views. Note that, these index paths are available only if their views are contained within the table view. To learn more about the information provided by the context, see see UITableViewFocusUpdateContext.

See Also

Managing table view focus