1. #1
    Sencha User tf.alves's Avatar
    Join Date
    Feb 2010
    Location
    Portugal
    Posts
    54
    Answers
    3
    Vote Rating
    0
    tf.alves is on a distinguished road

      0  

    Default Answered: Scroll to list item on itemTap event

    Answered: Scroll to list item on itemTap event


    Hi everyone,

    I want to scroll to the selected item on a list. My problem is, the itemTap event is passing me a DataView to my Controller Action. As you know, the DataView doesn't have a "scroller" instance, nor scrolling behavior related methods. How do I get my list, and how do I get it to scroll to the selected item?

    I suppose the scroller.scrollTo method still exists in Sencha Touch 2... but if I could only get the List instead of a DataView...

    Please help!

    P.s. I'm currently using the Sencha Designer

  2. You can call dataview.getScrollable() and if that returns a Scrollable instance, call getScroller() to get the scroller. Then call scrollTo as needed.

  3. #2
    Sencha User Jamie Avins's Avatar
    Join Date
    Mar 2007
    Location
    Redwood City, California
    Posts
    3,661
    Answers
    17
    Vote Rating
    20
    Jamie Avins is a jewel in the rough Jamie Avins is a jewel in the rough Jamie Avins is a jewel in the rough

      0  

    Default


    You can call dataview.getScrollable() and if that returns a Scrollable instance, call getScroller() to get the scroller. Then call scrollTo as needed.

    Sencha Inc

    Jamie Avins

    @jamieavins

  4. #3
    Sencha User tf.alves's Avatar
    Join Date
    Feb 2010
    Location
    Portugal
    Posts
    54
    Answers
    3
    Vote Rating
    0
    tf.alves is on a distinguished road

      0  

    Default


    Thanks Jamie! I tried that before but wasn't getting the results I wanted, so I thought it wasn't the proper way of doing this. I just found the method documentation in the API Docs! The getScroller method description was rather confusing to me.

    Thanks once again, you guys rock!

Thread Participants: 1

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi