List scrolling in WP7.5 Mango apps like foursquare and facebook

I am working on an application that shows search results based on the query you entered. And I add an endless scroll to that. In WP7.5, the list has vertical squeeze and horizontal squeeze events where we can start fetching results and updating the ItemsControl or Listbox. In parallel with this, I have variable height layouts that force the listbox to recalculate heights while scrolling, and this flickers during that time, since virtualization does not work in this case.

But how it's done in apps like foursquare and facebook is very interesting. The list box is left with some white space at the end when it reaches the end, and the results are then appended to the end, filling in the empty space. And infinite scrolling is achieved very well with no flicker. And when we scroll to the top, the controls are loaded with no data other than the header. Does it help the list without recalculating the height of the layout when there are multi-size layouts. Can someone explain to me how they do it, if anyone got it?

Thanks in advance.

+3


source to share


1 answer


I think, instead of calculating the height every time, why not just use the stack bar with height = "auto" and that each of your data goes into it. create a custom control and add it at runtime. make your life easy this way. (no blank spaces, auto scrolling and height calculation)



and for four square boxes, this will be inside your user control

0


source







All Articles