When i am using panResponders on iOS devices it works properly but same code when i run on android devices it is not working as expected. Code is as below
componentWillMount() {
this._panResponder = PanResponder.create({
onStartShouldSetPanResponder: (evt, gestureState) => true,
onStartShouldSetPanResponderCapture: (evt, gestureState) => true,
onMoveShouldSetPanResponder: (evt, gestureState) => true,
onMoveShouldSetPanResponderCapture: (evt, gestureState) => true,
onPanResponderGrant: (evt, gestureState) => {
return true;
},
onPanResponderTerminationRequest: (evt, gestureState) => {
console.log('getting on android');
return false;
},
onPanResponderRelease: (evt, gestureState) => {
console.log('getting here')
return true;
},
onPanResponderTerminate : (evt, gestureState) => {
console.log('gets');
}
});
}
Also my scrollView snippet is as below.
<ScrollView
ref={ref => this.myScroll = ref }
{...this._panResponder.panHandlers}>