Skip to content

Commit

Permalink
3D Touch fix: Add "rejectResponderTermination" prop to Touchables (ma…
Browse files Browse the repository at this point in the history
…stermoo#267)

fix: unresponsiveness of buttons on devices with 3d touch
  • Loading branch information
IgorVanian authored and mastermoo committed Jan 3, 2020
1 parent cd5c523 commit 8df917c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions ActionButton.js
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,7 @@ export default class ActionButton extends Component {
]}
>
<Touchable
rejectResponderTermination
testID={this.props.testID}
accessible={this.props.accessible}
accessibilityLabel={this.props.accessibilityLabel}
Expand Down Expand Up @@ -301,6 +302,7 @@ export default class ActionButton extends Component {
_renderTappableBackground() {
return (
<TouchableOpacity
rejectResponderTermination
activeOpacity={1}
style={this.getOverlayStyles()}
onPress={this.reset.bind(this)}
Expand Down
2 changes: 2 additions & 0 deletions ActionButtonItem.js
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,7 @@ export default class ActionButtonItem extends Component {
>
<View>
<Touchable
rejectResponderTermination
testID={this.props.testID}
accessibilityLabel={this.props.accessibilityLabel}
background={touchableBackground(
Expand Down Expand Up @@ -181,6 +182,7 @@ export default class ActionButtonItem extends Component {

return (
<TextTouchable
rejectResponderTermination
background={touchableBackground(
this.props.nativeFeedbackRippleColor,
this.props.fixNativeFeedbackRadius
Expand Down

0 comments on commit 8df917c

Please sign in to comment.