Anything you need at init time usually doesn't belong in a module, it
should just be in the main app, probably as a class of some kind like
one of our managers.

 

All modules should simply import that class so they can compile against
it, and then -extern that class in MXMLC so it doesn't get linked into
the modules.

 

I would make the move to modules right away so you're not tempted to use
Application.application and get the wrong scope.

 

Have you looked through the modules slides on my blog?
http://blogs.adobe.com/aharui/2007/03/modules.html

 

-Alex

 

________________________________

From: [email protected]
[mailto:[EMAIL PROTECTED] On Behalf Of shawn.gibson
Sent: Monday, July 09, 2007 5:46 AM
To: [email protected]
Subject: [flexcomponents] Re: "Property leftCan not found on Main and
there is no default value"

 

Yeah, my server is very touchy (or touched LOL), times out very
easily. I'll be glad when my real box is back from the shop...

The code I sent you was an example of how I want it to look, but the
main body canvas is meant to be nothing but a ModuleLoader, with the
Module loaded into it, ideally. 

I will keep playing as it sounds like you are saying I shouldn't have
any issues, just figure the right way of scoping for each
id/property/variable/etc. based on the direction of flow from
app<>module and use document, this, parentDocument,
Application.application...etc.

I DO have to figure out how to put all my main AS into a package, so
it's immediately available for initialization purposes across the
entire app, all modules when needed etc., but one step at a time...

So I'll keep trying.

Thanks very much for your help;)

Shawn

 

Reply via email to