Fix measureInWindow for view-backed Nodes

Summary:
This patch fixes measureInWindow for Nodes backed by Views.
Whereas the intention was to call the super implementation when we have a
Node backed by a View, we instead called the super implementation of
measure, which doesn't measure relative to window.

Differential Revision: D3607890
This commit is contained in:
Ahmed El-Helw 2016-07-22 15:14:46 -07:00
Родитель 690368fc3f
Коммит 520f70bd57
1 изменённых файлов: 5 добавлений и 1 удалений

Просмотреть файл

@ -195,7 +195,11 @@ public class FlatUIImplementation extends UIImplementation {
FlatShadowNode node = (FlatShadowNode) resolveShadowNode(reactTag);
if (node.mountsToView()) {
mStateBuilder.ensureBackingViewIsCreated(node);
super.measure(reactTag, callback);
if (relativeToWindow) {
super.measureInWindow(reactTag, callback);
} else {
super.measure(reactTag, callback);
}
return;
}