Files
burrow-server/tools/decompiled/old-builds/b1188/gui/ItemWindowGame.as
T

63 lines
1.9 KiB
ActionScript

package gui
{
import flash.display.DisplayObject;
import flash.display.MovieClip;
import flash.events.MouseEvent;
public class ItemWindowGame extends ItemWindowBase
{
public function ItemWindowGame(param1:Function, param2:Object, param3:String, param4:int, param5:Function = null, param6:Function = null, param7:Function = null, param8:Function = null, param9:Object = null)
{
super("gameBtnCont",param1,param2,param3,param4,param5,param6,param7,param8);
}
public function get itemLayer() : MovieClip
{
return _window.itemLayer;
}
override public function loadCurrItem(param1:int = 0, param2:int = 0) : void
{
_itemYLocation = param1;
_itemXLocation = param2;
if(Boolean(_currItem) && !_isCurrItemLoaded)
{
_isCurrItemLoaded = true;
if(_iconLayerName != "" && _currItem.hasOwnProperty(_iconLayerName))
{
_window.itemLayer.addChild(_currItem[_iconLayerName]);
}
else
{
_window.itemLayer.addChild(DisplayObject(_currItem));
}
}
}
override protected function addEventListeners() : void
{
if(_window)
{
if(_mouseDown != null)
{
addEventListener(MouseEvent.MOUSE_DOWN,_mouseDown,false,0,true);
}
if(_mouseOver != null)
{
addEventListener(MouseEvent.ROLL_OVER,_mouseOver,false,0,true);
}
if(_mouseOut != null)
{
addEventListener(MouseEvent.ROLL_OUT,_mouseOut,false,0,true);
}
if(_memberOnlyDown != null)
{
addEventListener(MouseEvent.MOUSE_DOWN,_memberOnlyDown,false,0,true);
}
}
}
}
}