mirror of
https://github.com/burrow-dev/burrow-server.git
synced 2026-11-19 01:27:51 -05:00
Brought up to date with the private repository (feea4c7)
This commit is contained in:
1 parent
1aa738d692
commit
1b1df1ae48
7925 files changed
+2617237
-20
No files matched your search
@@ -0,0 +1,70 @@
|
||||
package gui.itemWindows
|
||||
{
|
||||
public class ItemWindowPattern extends ItemWindowBase
|
||||
{
|
||||
|
||||
public static const TYPE_SWATCH:String = "swatch";
|
||||
|
||||
public static const TYPE_MESSAGE:String = "message";
|
||||
|
||||
public static const TYPE_POST:String = "post";
|
||||
|
||||
public static const TYPE_REPLY:String = "reply";
|
||||
|
||||
private var _type:String;
|
||||
|
||||
private var _patternIndexOrName:Object;
|
||||
|
||||
private var _colorIndexOrName:Object;
|
||||
|
||||
public function ItemWindowPattern(param1:Function, param2:Object, param3:String, param4:int, param5:Function, param6:Function, param7:Function, param8:Function, param9:Object)
|
||||
{
|
||||
_type = param9.type;
|
||||
_patternIndexOrName = param9.patternIndex != null ? param9.patternIndex : param4 + 1;
|
||||
_colorIndexOrName = param9.colorIndex != null ? param9.colorIndex : 1;
|
||||
super(param2,param1,param2,param3,param4,param5,param6,param7,param8,false);
|
||||
}
|
||||
|
||||
override protected function onWindowLoadCallback() : void
|
||||
{
|
||||
setChildrenAndInitialConditions();
|
||||
addEventListeners();
|
||||
super.onWindowLoadCallback();
|
||||
}
|
||||
|
||||
override protected function setChildrenAndInitialConditions() : void
|
||||
{
|
||||
if(_window)
|
||||
{
|
||||
_window.gotoAndStop(_type);
|
||||
_window[_type + "Btn"].pattern.gotoAndStop(_patternIndexOrName);
|
||||
_window[_type + "Btn"].updateColor(_colorIndexOrName);
|
||||
}
|
||||
}
|
||||
|
||||
public function getCurrentPatternIndex() : int
|
||||
{
|
||||
return _window[_type + "Btn"].pattern.currentFrame;
|
||||
}
|
||||
|
||||
public function setPatternAndColor(param1:Object, param2:Object) : void
|
||||
{
|
||||
_colorIndexOrName = param2;
|
||||
_patternIndexOrName = param1;
|
||||
setChildrenAndInitialConditions();
|
||||
}
|
||||
|
||||
public function setColor(param1:Object) : void
|
||||
{
|
||||
_colorIndexOrName = param1;
|
||||
setChildrenAndInitialConditions();
|
||||
}
|
||||
|
||||
public function setPattern(param1:Object) : void
|
||||
{
|
||||
_patternIndexOrName = param1;
|
||||
setChildrenAndInitialConditions();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user