1. #11
    Sencha User bluehipy's Avatar
    Join Date
    Mar 2010
    Location
    Romania
    Posts
    604
    Answers
    66
    Vote Rating
    26
    bluehipy will become famous soon enough bluehipy will become famous soon enough

      0  

    Default


    You should not need the item index in component and ... you should not make a component dependent of its parents normally. It's some how against the intention of mvc. How so ever you can use up() to get the DataItem container as well as the DataView itself so having these references and the actual data item you can easily get the item index:

    http://docs.sencha.com/touch/2.2.0/#...d-getItemIndex
    Latest thoughts on the subject: http://joy2share.com/senchatouch/

  2. #12
    Sencha User =NR='s Avatar
    Join Date
    Mar 2013
    Location
    Singapore
    Posts
    91
    Vote Rating
    1
    =NR= is on a distinguished road

      0  

    Default


    Quote Originally Posted by bluehipy View Post
    You should not need the item index in component and ... you should not make a component dependent of its parents normally. It's some how against the intention of mvc. How so ever you can use up() to get the DataItem container as well as the DataView itself so having these references and the actual data item you can easily get the item index:

    http://docs.sencha.com/touch/2.2.0/#...d-getItemIndex
    hmm..,

    thank you for the "getItemIndex" clue been looking for such a thing and could not find it yesterday instead i have to do merry go around with getting the store first then get the item index on the store and save it as the item index.

    the get itemIndex is without doubt is the much simpler way of getting the item index ( i need the item index in order to pass it to other modules of this app its been there before i got involved and will be needing a lot of effort if i want to change that so i'll just use it as it is)

    that is a good point about not making the child component dependent of the parent, will definitely mark this in my brain so i will not easily do this kind of stuff again in the future..


    thank you bluehipy for your guidance it definitely helped me!

    *just being curious though from where do you learn sencha touc






  3. #13
    Sencha User bluehipy's Avatar
    Join Date
    Mar 2010
    Location
    Romania
    Posts
    604
    Answers
    66
    Vote Rating
    26
    bluehipy will become famous soon enough bluehipy will become famous soon enough

      0  

    Default


    In child components you could fire events that you can catch later on parent containers, this way you can keep them independent.

    *
    I had a great teacher, I am self taught
    Mainly I have read all docs + tutorials + watched videos:
    http://docs.sencha.com/touch/2.2.0/#!/guide
    http://docs.sencha.com/touch/2.2.0/#!/video

    also I am constantly checking sources for everything from Ext.Base ~ Ext.Component to Ext.dataview.Dataview, layouts, models, proxies, stores etc

    and intensively worked on projects based on st1, st2.0 ~ st2.1 for the last years
    Latest thoughts on the subject: http://joy2share.com/senchatouch/

  4. #14
    Sencha User =NR='s Avatar
    Join Date
    Mar 2013
    Location
    Singapore
    Posts
    91
    Vote Rating
    1
    =NR= is on a distinguished road

      0  

    Default


    Quote Originally Posted by bluehipy View Post
    In child components you could fire events that you can catch later on parent containers, this way you can keep them independent.

    I had a great teacher, I am self taught
    Mainly I have read all docs + tutorials + watched videos:
    http://docs.sencha.com/touch/2.2.0/#!/guide
    http://docs.sencha.com/touch/2.2.0/#!/video

    also I am constantly checking sources for everything from Ext.Base ~ Ext.Component to Ext.dataview.Dataview, layouts, models, proxies, stores etc

    and intensively worked on projects based on st1, st2.0 ~ st2.1 for the last years
    thats and interesting idea, will give it a try..

    your teacher isn't great at all he's AWESOME!!
    hahaha..

    thanks bluehipy

  5. #15
    Sencha User bluehipy's Avatar
    Join Date
    Mar 2010
    Location
    Romania
    Posts
    604
    Answers
    66
    Vote Rating
    26
    bluehipy will become famous soon enough bluehipy will become famous soon enough

      0  

    Default


    He he
    Thanks =NR=, you 're cool

    peace
    Latest thoughts on the subject: http://joy2share.com/senchatouch/

Thread Participants: 3

Tags for this Thread

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