Adobe Systems, Inc.

ExtensionModule.as

Go to the documentation of this file.
00001 /******************************************************************
00002 ** Copyright 2005-2006 Adobe Systems Incorporated
00003 ** Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt
00004 ** or a copy at http://opensource.adobe.com/licenses.html)
00005 **
00006 ** ExtensionModule Class 
00007 ********************************************************************/
00008 
00009 import mx.xpath.XPathAPI;
00010 import amg.*;
00011 
00012 //implements ISmartLoader interface insuring that the smartLoader callback method is present
00013 class amg.ExtensionModule extends MovieClip {
00014         //member properties
00015         
00016         private var Background:MovieClip;
00017         private var mcLoader:MovieClipLoader;
00018         private var ExtensionClip:MovieClip;
00019         private var Extension:MovieClip;
00020         public var LoadingClip:MovieClip;
00021         public var _iControlWidth:Number;
00022         public var _iControlHeight:Number;
00023         public var _oNodeContext:XMLNode;
00024         public var strBaseRefUrl:String="";
00025         
00026         //class constructor
00027         public function ExtensionModule() {
00028                 this.Background         = this.attachMovie("ExtensionControlBg", "ExtensionControlBg", this.getNextHighestDepth());
00029                 this.ExtensionClip      = this.createEmptyMovieClip("extensionClip",this.getNextHighestDepth());
00030                 this.LoadingClip        = this.attachMovie("LoadingCircle","mapLoader_mc", this.getNextHighestDepth());
00031 
00032                 this.LoadingClip._width = 30;
00033                 this.LoadingClip._height = 30;
00034                 this.LoadingClip._x = (Stage.width/2)-(this.LoadingClip._width/2);
00035                 this.LoadingClip._y = (Stage.height/2)-(this.LoadingClip._height/2);
00036                 
00037                 mcLoader = new MovieClipLoader();
00038                 mcLoader.addListener(this);
00039         }
00040         
00041         public function loadModule(swfModule:String,baseRefUrl:String):Void{
00042                 mcLoader.loadClip(baseRefUrl+swfModule,ExtensionClip);
00043                 this.strBaseRefUrl = baseRefUrl;
00044         }
00045         
00046         function onLoadInit(target_mc:MovieClip) {
00047                 
00048         }
00049         
00050         
00051         public function parseMediaGroup(xmlMediaGroup:XMLNode) {
00052                 this._oNodeContext = xmlMediaGroup;
00053         }
00054         
00055         
00056         
00057         public function mapHasLoaded(){
00058                 //called when map component has loaded
00059         }
00060 
00061         public function dispatchEvent(eventName:String,eventValue:Object):Void{
00062                 
00063                 _parent.dispatchEvent(eventName,eventValue);
00064 
00065         }
00066         
00067         public function setHeightWidth(h:Number, w:Number):Void {
00068                 _root.gallery.writeDebug("EM setHeightWidth");
00069                 this._iControlWidth = w;
00070                 this._iControlHeight = h;
00071                 
00072                 this.ExtensionClip.setHeightWidth(h,w);
00073 
00074                 //photo frame Background
00075                 this.Background.drawRectangle(w,h,7);
00076         }
00077 
00078 }

Copyright © 2006 Adobe Systems Incorporated.

Use of this website signifies your agreement to the Terms of Use and Online Privacy Policy.