Don't block scroll when using non-touchable visible row for SwipeableRow
Summary: **motivation** Currently when using a non-touchable visible row for a SwipeableRow, the scroll on list view is blocked. **Test Plan** ``` <SwipeableListView dataSource={dataSource} renderRow={() => <View style={styles.row}/>} renderQuickActions={() => <View style={styles.hiddenrow}/>} /> ``` * Tested that when using non-touchable for renderRow allows scrolling on list view. * Tested that when using touchable for renderRow allows scrolling on list view. cc fred2028 Closes https://github.com/facebook/react-native/pull/8537 Differential Revision: D3542407 Pulled By: fred2028 fbshipit-source-id: b7ad7ff7c7dd1b717544746a85bb265414aa18f4
This commit is contained in:
parent
a2c6a7bc64
commit
13a19a8897
|
@ -128,10 +128,6 @@ const SwipeableRow = React.createClass({
|
||||||
|
|
||||||
componentWillMount(): void {
|
componentWillMount(): void {
|
||||||
this._panResponder = PanResponder.create({
|
this._panResponder = PanResponder.create({
|
||||||
onStartShouldSetPanResponder: (event, gestureState) => true,
|
|
||||||
// Don't capture child's start events
|
|
||||||
onStartShouldSetPanResponderCapture: (event, gestureState) => false,
|
|
||||||
onMoveShouldSetPanResponder: (event, gestureState) => false,
|
|
||||||
onMoveShouldSetPanResponderCapture: this._handleMoveShouldSetPanResponderCapture,
|
onMoveShouldSetPanResponderCapture: this._handleMoveShouldSetPanResponderCapture,
|
||||||
onPanResponderGrant: this._handlePanResponderGrant,
|
onPanResponderGrant: this._handlePanResponderGrant,
|
||||||
onPanResponderMove: this._handlePanResponderMove,
|
onPanResponderMove: this._handlePanResponderMove,
|
||||||
|
|
Loading…
Reference in New Issue