Re: [Flashcoders] AS2 Dispatch Custom Event of loaded clip

2008-08-17 Thread Helmut Granda
Hi Juan, Thanks for the tip, it does makes sense since I had to create something similar in a different application in AS3 and your sample works just as expected. Thanks again, Helmut On Sat, Aug 16, 2008 at 5:42 PM, Juan Pablo Califano [EMAIL PROTECTED] wrote: Assuming that modifying the

Re: [Flashcoders] AS2 Dispatch Custom Event of loaded clip

2008-08-17 Thread Steven Sacks
Wow. That's a crazy amount of code for something so simple. Here's what I use: --- import mx.events.EventDispatcher; class net.stevensacks.utils.ObservableClip extends MovieClip { public var addEventListener:Function; public var

Re: [Flashcoders] AS2 Dispatch Custom Event of loaded clip

2008-08-17 Thread Juan Pablo Califano
Well, if you consider that adding a static function and a static variable to get the Singleton working is a crazy amount of code, I'd have to agree with you... Because the rest, well, it's just the same, with the difference that I'm using a named event (for lack of a better word, I mean public

Re: [Flashcoders] AS2 Dispatch Custom Event of loaded clip

2008-08-17 Thread Helmut Granda
On Sun, Aug 17, 2008 at 4:53 PM, Juan Pablo Califano [EMAIL PROTECTED] wrote: However, in this scenario you're loading an swf into an empty MovieClip (which extends ObservableClip, if I didn't get you wrong). That means that when the swf is loaded, your stager empty MovieClip has lost all

Re: [Flashcoders] AS2 Dispatch Custom Event of loaded clip

2008-08-16 Thread Juan Pablo Califano
Assuming that modifying the custom application is not possible, but that you can change mySWF.swf, you can use an event manager that acts as a proxy for dispatching events. So, instead of dispatching the event directly from your object, you use the service of a third party. You register to that

[Flashcoders] AS2 Dispatch Custom Event of loaded clip

2008-08-15 Thread Helmut Granda
I have the following: code.customApplication.load(mySWF.swf, myClip_mc); now the custom application does not dispatch any events such as onComplete, this wasnt built in the original application so what I want to do is dispatch an event from mySWF.swf but of course when it is loaded into