I need to create a UI which is a mix of UITableView
, UITextField
, and some custom UIView
's and I also need to provide a custom focus animation.
How can I get the UITableView
/UITableViewCell
and UITextField
to not render the default focus animations?
I tried:
override func didUpdateFocusInContext(context: UIFocusUpdateContext, withAnimationCoordinator coordinator: UIFocusAnimationCoordinator) {
if let view = context.previouslyFocusedView {
view.layer.removeAllAnimations()
}
if let view = context.nextFocusedView {
view.layer.removeAllAnimations()
}
}
I can add my own animations, but can't get rid of the 'default' animations from the view.