6 Replies Latest reply on Apr 10, 2009 3:45 PM by essa tkinen

    how to call a function in a component when certain viewStack selected

    essa tkinen Level 1

      K I'm pretty sure my way around this is to use a custom event but maybe someone out there knows different.

       

      This is my views layout

       

      mainapp > allVideos > video - videoPlayer Component

       

      Ok I go to allVideos select my video viewsStack changes to video view init() is called on creation complete sends a property to my videoPlayer component and everything works nice.

      Now I navigate back to allVideos and select a new video we go back to videos view and I need a way to call init() again so I can send my new property to my component to play the new video. Creation Complete doesn't get called again.

       

      I was reading into currentStateChange or currentStateChanging events. I don't really understand how those work. So I'm guess custom events are the way to go? Thanks guys and influence is grateful.