mirror of
https://github.com/status-im/react-native.git
synced 2025-01-14 03:26:07 +00:00
Bugfix: Make iOS Slider it the responder
Summary:This fixes issues with other view (like the Navigator) stealing the responder and becoming interactive while the user is dragging the slider. From [documentation](https://facebook.github.io/react-native/docs/gesture-responder-system.html): - `onStartShouldSetResponder`: Does this view want to become responder on the start of a touch? -> Yes. - `onResponderTerminationRequest`: Something else wants to become responder. Should this view release the responder? -> No. Reviewed By: ericvicenti Differential Revision: D3133337 fb-gh-sync-id: 3d7e1e6a2ed6fa605857cfb0549ffa71df85fd22 fbshipit-source-id: 3d7e1e6a2ed6fa605857cfb0549ffa71df85fd22
This commit is contained in:
parent
2f2703936d
commit
52ddfd9b51
@ -131,7 +131,11 @@ var SliderIOS = React.createClass({
|
||||
onSlidingComplete && onSlidingComplete(event.nativeEvent.value);
|
||||
});
|
||||
|
||||
return <RCTSlider {...props}/>;
|
||||
return <RCTSlider
|
||||
{...props}
|
||||
onStartShouldSetResponder={() => true}
|
||||
onResponderTerminationRequest={() => false}
|
||||
/>;
|
||||
}
|
||||
});
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user