1. #1
    Sencha User
    Join Date
    May 2007
    Posts
    18
    Vote Rating
    0
    Graaf is on a distinguished road

      0  

    Default Manually 'tap' an item in a (nested)list?

    Manually 'tap' an item in a (nested)list?


    Is there a way to manually 'tap' an item in an (nested)list ?

    Example:

    I have a button in the dashboard of my webapp, and I want that button to open the 2nd tab and go to the 1st item of the (nested)list item and show the child items.

  2. #2
    Sencha User
    Join Date
    May 2007
    Posts
    18
    Vote Rating
    0
    Graaf is on a distinguished road

      0  

    Default


    What I mean is .. programmatically 'click' on one of the items on the first level so childs wil be shown.

  3. #3
    Sencha User
    Join Date
    May 2007
    Posts
    18
    Vote Rating
    0
    Graaf is on a distinguished road

      0  

    Default


    anyone?

  4. #4
    Sencha User tomalex0's Avatar
    Join Date
    Apr 2009
    Location
    San Jose, CA
    Posts
    589
    Vote Rating
    16
    tomalex0 will become famous soon enough

      0  

    Default


    Below code will probably helps to select nestedlist items.


    Code:
    xtype:'button',
    text :'Nested',
    handler:function(btn,e){
         var activelist= nestedPanel.getActiveItem();
         var listselectednode = activelist.getNode(1);
         nestedPanel.fireEvent('itemtap',activelist,1,listselectednode ,e);
    }
    and if u want to dynamically select tab , you can use fireEvent('change',) for Tabbar

    Hope this helps

  5. #5
    Sencha User
    Join Date
    May 2007
    Posts
    18
    Vote Rating
    0
    Graaf is on a distinguished road

      0  

    Default


    A little ...

    Code:
       
     Ext.get('button-id').addListener('tap', function(e) {
          Ext.getCmp('viewport').setActiveItem(1);
          var activeList = Ext.getCmp('listComponent').getActiveItem();
          var listSelectedNode = activeList.getNode(0);
          Ext.getCmp('listComponent').fireEvent('itemtap', activeList, 0, listSelectedNode, e);
          
        });
    this is what i do. . 'buttns' on home screen are html "buttons" so that's why I'm doing the get('..')

    But this doesn't work correctly .. I need some nestedlist reset ( without reloading all data ) before going there because it remembers wrong.
    When I tap the button, go back home and tap again .. the back button in the nestedlist goes back to itself one time.
    And sometimes I see a backbutton on the nestedlist root ... weirdness

  6. #6
    Sencha User tomalex0's Avatar
    Join Date
    Apr 2009
    Location
    San Jose, CA
    Posts
    589
    Vote Rating
    16
    tomalex0 will become famous soon enough

      0  

  7. #7
    Sencha User
    Join Date
    May 2007
    Posts
    18
    Vote Rating
    0
    Graaf is on a distinguished road

      0  

    Default


    Ok!

    Thank you so much! This solved my problem.

  8. #8
    Sencha User
    Join Date
    Oct 2011
    Posts
    5
    Vote Rating
    0
    Jamesaya is on a distinguished road

      0  

    Default Removed

    Removed


    getNode() has been removed in ST2.Is there any alternative methods?

Similar Threads

  1. How to slide the list once an item is tap?
    By pajelawrence in forum Sencha Touch 1.x: Discussion
    Replies: 15
    Last Post: 4 Feb 2011, 3:20 AM
  2. Strategy Request: Overlay On List Item Tap
    By claytantor in forum Sencha Touch 1.x: Discussion
    Replies: 1
    Last Post: 3 Jan 2011, 10:04 AM
  3. Nested List Item - Custom Styles?
    By fernie in forum Sencha Touch 1.x: Discussion
    Replies: 4
    Last Post: 20 Oct 2010, 5:52 AM
  4. Nested List having Form Panel and other as its item
    By tomalex0 in forum Sencha Touch 1.x: Discussion
    Replies: 1
    Last Post: 16 Sep 2010, 6:39 AM
  5. How to embed an icon in a nested list item?
    By meyerovb in forum Sencha Touch 1.x: Discussion
    Replies: 2
    Last Post: 15 Jul 2010, 4:04 AM

Thread Participants: 2

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar