TouchableHighlight child on 6s+ #38
Comments
I'm also having the same issue ONLY on my iPhone 6s. As @deanmcpherson was saying, it works fine on all of my other devices and also the 6s simulator. I also thought it has something to do with 3d touch, but I disabled it on my phone and was still having the issue. (However, I'm not sure if disabling it in settings is the same as not having that feature at all on a phone) I haven't tested if it on an iPhone 6s plus. |
@coderdave It is the same on the 6s and 6s plus, I'll see if I can debug it today. |
As per facebook/react-native#3082, this was resolved for me by checking if dy/ dx is not 0 before granting a PanResponder in onMoveShouldSetPanResponder. |
@deanmcpherson So what's the workaround code to fix it until FB fixes it internally? |
@deanmcpherson I would also like to know what your current workaround is. Can you share it? edit: figured it out. I interpreted the _handleMoveShouldSetPanResponder: function(e: Object, gestureState: Object): boolean {
if (gestureState.dx === 0 || gestureState.dy === 0) {
return false;
}
return true;
} |
hey @por, @coderdave sorry for the slow reply, @por's solution is the same as mine. |
Thanks. Ok, so we're basically having to override the Would it make sense to update react-native-swipeout and release a new version? It seems like it's on react's radar but hasn't been fixed yet. |
fyi created a pull request for future reference |
Hey @dancormier, I'm having some issues getting this to work on the 6s+. It works as expected on every other device I've tested, but a child TouchableHighlight does not respond to being pressed on a 6s+. This may be an issue with react-native itself.
The swipeout action itself works, but the panResponder appears to block the onPress from firing on child elements. I did some research and found https://botbot.me/freenode/reactnative/2015-08-28/?page=8 which refers to a similar issue, though I was wondering whether something in the new "3d touch" that may get in the way of correctly passing the onPress action.
The text was updated successfully, but these errors were encountered: