Hi Helmut,

It seems, that objects loaded through an .swf from an different domain,
does not dispatch any events :| so that's why my code is wrong.

What i meant, was: the function i posted, generates an simple navigation
using an class loaded from an .swf (different domain) through the Bulkloader (which essentially does the same what the Loader class does, with some nice extras)

var nav_item : MovieClip = new navItem as MovieClip;

This casts the class loaded from that .swf as MovieClip, and it seems to be the problem, what i don't understand is, i actually don't add the event listener to this objects, but to the holder containing it, hence it still should fire the event, but it does not :|

navItem = assets.loaderInfo.applicationDomain.getDefinition("navItem") as Class; picThumb = assets.loaderInfo.applicationDomain.getDefinition("picThumb") as Class;

here i initialize the loaded .swf's symbols from the library as Class, maybe my
approach is simply wrong,

Any tips on that?

On Jul 29, 2008, at 10:32 PM, Helmut Granda wrote:

could you elaborate on your question?
"Here is the whole function i use to, adding the same listeners to another object fires those without any prblems :| can someone explain to me what is
wrong?"

I personally dont understand correctly what you are trying to achieve...

On Tue, Jul 29, 2008 at 2:07 PM, Patrick J. Jankun <[EMAIL PROTECTED]> wrote:

Here is the whole function i use to, adding the same listeners to another object fires those without any prblems :| can someone explain to me what is
wrong?

private function initNav() : void {
      navHolder = new Sprite;
navHolder.addEventListener(MouseEvent.MOUSE_OVER, navOnMouseOver); navHolder.addEventListener(MouseEvent.MOUSE_OUT, navOnMouseOut);
      navHolder.addEventListener(MouseEvent.CLICK, navOnMouseClick);
      navHolder.addEventListener(Event.MOUSE_LEAVE, navOnMouseOut);

      for (var i : int = 0;i < navItemsTxt.length;i++) {
              var nav_item : MovieClip = new navItem as MovieClip;

              nav_item.tf.text = navItemsTxt[i];
              nav_item.tf.selectable = false;

              nav_item.bg.alpha = .2;

              nav_item.y += (nav_item.height + vertGap) * i;

              navHolder.addChild(nav_item);
      }

      navHolder.x = 20;
      navHolder.y = stage.stageHeight - navHolder.height - 20;

      stage.addEventListener(Event.RESIZE, stageResized);
      addChild(navHolder);
}
_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders




--
...helmut
_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to