Re: [Flashcoders] Q: Including class at compile w/o explicitly instantiating it

2007-08-13 Thread Alan MacDougall
Steven Sacks wrote: If you do not do anything with an imported class, Flash will not compile it. Or, to take it a step further, make a class named ClassRegistry (or some such), which defines but does not instantiate private static instances of every class you want to load dynamically. Then

[Flashcoders] Q: Including class at compile w/o explicitly instantiating it

2007-08-10 Thread Rick Terrill
Hi everyone, it's my first time posting to the board. I'm trying to figure something out, or if it's even possible. I would like to dynamically instantiate a class (via getDefinitionByName) but without explicitly instantiating the object prior in the class. An example (this is what I would like

Re: [Flashcoders] Q: Including class at compile w/o explicitly instantiating it

2007-08-10 Thread Steve Mathews
Try just doing: var ssc:SomeSweetClass; On 8/10/07, Rick Terrill [EMAIL PROTECTED] wrote: Hi everyone, it's my first time posting to the board. I'm trying to figure something out, or if it's even possible. I would like to dynamically instantiate a class (via getDefinitionByName) but without

RE: [Flashcoders] Q: Including class at compile w/o explicitly instantiating it

2007-08-10 Thread Seth Caldwell
Sent: Friday, August 10, 2007 2:37 PM To: [EMAIL PROTECTED]; flashcoders@chattyfig.figleaf.com Subject: Re: [Flashcoders] Q: Including class at compile w/o explicitly instantiating it Try just doing: var ssc:SomeSweetClass; On 8/10/07, Rick Terrill [EMAIL PROTECTED] wrote: Hi everyone, it's my

Re: [Flashcoders] Q: Including class at compile w/o explicitly instantiating it

2007-08-10 Thread Steven Sacks
If you do not do anything with an imported class, Flash will not compile it. One direct solution is to make a static boolean var in the class and access it once and it will force the class to compile. var temp:Boolean = SomeClass.staticBoolean; ___