Errm - actually that's not such a good reason. The 'import' statement doesn't actually embed a class into the .swf. All it does is tell the compiler that when you type (for example) MyClass, you are actually referring to com.fred.MyClass.
You could just type com.fred.MyClass throughout the body of your code instead of typing import at the top of the file. 'import' is simply a disambiguation helper for the compiler. It's got nothing to do with what code actually gets included in the resultant .swf. You can prove this by typing: import com.fred.* // Replace with some set of classes you're not using in your current project And recompiling. The .swf file size won't go up until you actually _reference_ an object that belongs to one of those packages. As soon as you typed: var f:MyClass=new MyClass(); or, in fact var f:com.fred.MyClass=new com.fred.MyClass(); The file size would go up. So - in answer to RifledCloaca - no, you don't need to type 'import' at all, as long as you refer to all your classes by full packagename. Ian On 5/25/06, Merrill, Jason <[EMAIL PROTECTED]> wrote:
Because if Flash imported every class available to it automatically, then your .swf files would be huge and unnecessarily bloated. Do you really want the code to all the Remoting classes imported into your .swf if you're not using them? When you include, the actionscript cotained in the class is embedded in the .swf.
_______________________________________________ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com