return if UIManager failed to measure node
Summary: iOS return all 0 metrics for <Text> inside <Text>, which results immediate `onPressOut` event on press in. These kind of response should be ignored this solved issue #11462 Closes https://github.com/facebook/react-native/pull/11530 Differential Revision: D4541452 Pulled By: ericvicenti fbshipit-source-id: efd7bf1b380b1aecf7301b23f1fbd5a77a9e9095
This commit is contained in:
parent
9d7f2498f6
commit
6a5225fb22
|
@ -603,6 +603,10 @@ var TouchableMixin = {
|
||||||
},
|
},
|
||||||
|
|
||||||
_handleQueryLayout: function(l, t, w, h, globalX, globalY) {
|
_handleQueryLayout: function(l, t, w, h, globalX, globalY) {
|
||||||
|
//don't do anything UIManager failed to measure node
|
||||||
|
if (!l && !t && !w && !h && !globalX && !globalY) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
this.state.touchable.positionOnActivate &&
|
this.state.touchable.positionOnActivate &&
|
||||||
Position.release(this.state.touchable.positionOnActivate);
|
Position.release(this.state.touchable.positionOnActivate);
|
||||||
this.state.touchable.dimensionsOnActivate &&
|
this.state.touchable.dimensionsOnActivate &&
|
||||||
|
|
Loading…
Reference in New Issue