Skip to content

Commit

Permalink
Migrate TextInput to use new setNativeProps API
Browse files Browse the repository at this point in the history
Summary:
See react-native-community/discussions-and-proposals#72 for more information.

This shouldn't be a user facing change.

Reviewed By: shergin

Differential Revision: D14176217

fbshipit-source-id: 784739e5a69a98ddd1d5db75ee5267b7459e477b
  • Loading branch information
elicwhite authored and facebook-github-bot committed Mar 14, 2019
1 parent fc94ade commit b43aa23
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Libraries/Components/TextInput/TextInput.js
Original file line number Diff line number Diff line change
Expand Up @@ -1239,7 +1239,7 @@ const TextInput = createReactClass({
// Make sure to fire the mostRecentEventCount first so it is already set on
// native when the text value is set.
if (this._inputRef && this._inputRef.setNativeProps) {
this._inputRef.setNativeProps({
ReactNative.setNativeProps(this._inputRef, {
mostRecentEventCount: event.nativeEvent.eventCount,
});
}
Expand Down Expand Up @@ -1304,7 +1304,7 @@ const TextInput = createReactClass({
this._inputRef &&
this._inputRef.setNativeProps
) {
this._inputRef.setNativeProps(nativeProps);
ReactNative.setNativeProps(this._inputRef, nativeProps);
}

if (this.props.selectionState && selection) {
Expand Down

0 comments on commit b43aa23

Please sign in to comment.