Add some documenation notes, and remove some traces
[potlatch2.git] / net / systemeD / halcyon / styleparser / Eval.as
index 499710fc42791248767c9f680d179ffa3ebec4b9..c8c1095c06db4e017fd9661714a89a956138d420 100644 (file)
@@ -28,16 +28,18 @@ package net.systemeD.halcyon.styleparser {
                        var compiled:CompiledExpression=parser.parse();
                        var swfdata:ByteArray=compiled.compile();
 
-                       this.contentLoaderInfo.addEventListener(Event.COMPLETE, swfLoaded);
+                       this.contentLoaderInfo.addEventListener(Event.COMPLETE, swfLoaded, false, 0, true);
                        this.loadBytes(swfdata, new LoaderContext(false, new ApplicationDomain(ApplicationDomain.currentDomain)));
                }
                
                private function swfLoaded(event:Event):void {
                        var info:LoaderInfo = event.target as LoaderInfo;
                        swfclass=info.applicationDomain.getDefinition( "CompiledExpression" ) as Class;
+                       dispatchEvent(new Event("swf_loaded"));
                }
                
                public function exec(tags:Object):* {
+                       if (!swfclass) { return null; }
                        var cp:Object=new swfclass();
                        for (var k:String in tags) { cp[k]=tags[k]; }
                        return cp.execute();