1 Reply Latest reply on Mar 22, 2007 5:57 AM by matzeHuber

    Object navigation with FABridge

    matzeHuber
      HI all,

      I'm getting into troubles when trying to navigate a Flex-object-tree in JavaScript using the FABridge.

      I tried to add a changeListener to the slider on SDK example PhotoViewers slideshow:

      function addListener() {
      var displayCallback = function(event) {
      alert('slider changed');
      }
      var flexApp = FABridge.flash.root();
      var view = flexApp.getSlideshowView();
      var slider = view.getPhotoSlider();
      slider.addEventListener("changed", displayCallback);

      }
      I placed the bridge definition in the main PhotoViewer.mxml.

      I checked to execution with FireBug an the problem is that view.getPhotoSlider() returns null.

      Could this be the case because the photoSlider is defined in SlideShowView.mxml. and not in the toplevel PhotoView.mxml? Can only components defined in the toplevel mxml definition be accessed with the FABridge ?


      Hope anybody can help me with this

      regards
      Matthias