Instance Property

canBecomeFirstResponder

Returns a Boolean value indicating whether this object can become the first responder.

Declaration

var canBecomeFirstResponder: Bool { get }

Return Value

true if the receiver can become the first responder or false if it cannot.

Discussion

This method returns false by default. Subclasses must override this method and return true to be able to become first responder.

Do not call this method on a view that is not currently in the active view hierarchy. The result is undefined.

See Also

Managing the Responder Chain

var next: UIResponder?

Returns the next responder in the responder chain, or nil if there is no next responder.

var isFirstResponder: Bool

Returns a Boolean value indicating whether this object is the first responder.

func becomeFirstResponder() -> Bool

Asks UIKit to make this object the first responder in its window.

var canResignFirstResponder: Bool

Returns a Boolean value indicating whether the receiver is willing to relinquish first-responder status.

func resignFirstResponder() -> Bool

Notifies this object that it has been asked to relinquish its status as first responder in its window.