Good point. you do have to have at least one dangling reference in your
application for modules to work as expected.

 

Rick Winscot

 

 

From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Manish Jethani
Sent: Wednesday, March 26, 2008 4:48 AM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] Singletone class in Application and Modules !?

 

On 3/26/08, lytvynyuk <[EMAIL PROTECTED] <mailto:lytvynyuk%40yahoo.com> >
wrote:
>
> Is it true if I have singleton class instantiated in main application and
> in module, instances will be different?
[snip]

If you don't include the class in the main application, each of the
modules will have their own instance of the class. Class Foo in module
1 will be different from class Foo in module 2.

This is due to how modules are loaded in child application domains.
Read up on application domains in Flash (the ApplicationDomain class).

Also:

http://mannu.livejournal.com/372662.html

Manish

 

<<image001.jpg>>

<<image002.jpg>>

Reply via email to