TextInput: Unified support of clearsOnBeginEditing prop

Summary: The implementation of `clearsOnBeginEditing` was unified and moved to superclass.

Reviewed By: javache

Differential Revision: D5299396

fbshipit-source-id: 98c5494a782cbe4df5b2d6021828eb7b2012f6dc
This commit is contained in:
Valentin Shergin
2017-07-18 14:33:37 -07:00
committed by Facebook Github Bot
parent 8f93ce680d
commit cb96f1d5d2
7 changed files with 31 additions and 25 deletions

View File

@@ -329,16 +329,6 @@ static NSAttributedString *removeReactTagFromString(NSAttributedString *string)
}
}
- (BOOL)textInputShouldBeginEditing
{
if (_selectTextOnFocus) {
dispatch_async(dispatch_get_main_queue(), ^{
[self->_backedTextInput selectAll:nil];
});
}
return YES;
}
- (void)textInputDidBeginEditing
{
if (_clearTextOnFocus) {