Prevent crash when scrollEnabled used in singleline textinput (#23361)
Summary: Fixes #22949 , #21339. Currently, multiline textInput uses `UITextView` but singleline textInput uses `UITextField`, so singleline textinput may crash when use `scrollEnabled` property. [iOS] [Fixed] - Prevent crash when scrollEnabled used in singleline textinput Pull Request resolved: https://github.com/facebook/react-native/pull/23361 Differential Revision: D14030586 Pulled By: cpojer fbshipit-source-id: a8ae1b4e168469e65745c4d5e9329df8b6faa2aa
This commit is contained in:
parent
b8246ac89a
commit
9ff43abe65
|
@ -87,6 +87,16 @@
|
||||||
self.enabled = editable;
|
self.enabled = editable;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
- (void)setScrollEnabled:(BOOL)enabled
|
||||||
|
{
|
||||||
|
// Do noting, compatible with multiline textinput
|
||||||
|
}
|
||||||
|
|
||||||
|
- (BOOL)scrollEnabled
|
||||||
|
{
|
||||||
|
return NO;
|
||||||
|
}
|
||||||
|
|
||||||
#pragma mark - Context Menu
|
#pragma mark - Context Menu
|
||||||
|
|
||||||
- (BOOL)canPerformAction:(SEL)action withSender:(id)sender
|
- (BOOL)canPerformAction:(SEL)action withSender:(id)sender
|
||||||
|
|
Loading…
Reference in New Issue