Jun Huang
Jun Huang

Reputation: 11

Why UITextView/UITextField can't implement the UITextInput on iOS

Apple supply an example to implement the UITextInput based on a UIView. I tried to do the same thing based on the UITextView/UITextField but failed. That's why?

Thanks

Upvotes: 1

Views: 1054

Answers (1)

Cocoanetics
Cocoanetics

Reputation: 8245

Apple uses a private class as delegate for UITextInput on these classes. That means you cannot hook your own code in there because you cannot subclass a private class.

Upvotes: 1

Related Questions