mardi 1 avril 2014

Scroll when DataView loads

I want to scroll to a certain item in a DataView, when it loads.



I already have a function that scrolls the DataView to the right place. But I can't figure out when to call it.



I've tried using the view's "refresh" event, and the store's "load" event. Both are too early -- unless I add a delay, the view won't scroll.



The closest I can get is the view's scroller's "maxpositionchange" event. This seems to work, although I don't know enough about ST's scrollers to know if this is reliable. Also, I can see the data in the original position before it scrolls, which I'd like to avoid if possible.



Does anyone know a good way to find out when a DataView's data is ready to scroll?




Aucun commentaire:

Enregistrer un commentaire