microsoft / reactxp

Library for cross-platform app development.
https://microsoft.github.io/reactxp/
Other
8.29k stars 494 forks source link

RX.UserInterface.measureLayoutRelativeToAncestor differs in measuring scroll for platforms #826

Open ghost opened 5 years ago

ghost commented 5 years ago

Method RX.UserInterface.measureLayoutRelativeToAncestor gives different results for Electron and Web than for UWP, Android and iOS when measuring two elements where one is in a scrollable container (RX.ScrollView).

digitalergonom commented 5 years ago

I have a similar case, where RX.UserInterface.measureLayoutRelativeToWindow also do not provide correct information on mobile:

console.log('Will measure scrollview', scrollView)

RX.UserInterface.measureLayoutRelativeToWindow(scrollView).done((layoutinfo:RX.Types.LayoutInfo) => {
    console.log('Did measure scrollview', layoutinfo)
})

In web (Electron) this works out completly correct. On mobile all values received from the LayoutInfo are 0.

Looking forward to see a solution on this. :-)

fbartho commented 4 years ago

@shameister @ghostplant -- Do you think this is still an issue? If it is, it would either of you know what it would take to fix it?