// DHTML implementation of mbedlets
// (c) 1997 mBED Software, Inc.

function Point(h,v)
{
this.h = h;
this.v = v;
}
function _Cd(_v)
{
if (typeof(_v) == "string")
{
_Bv = _v.split(",");
return new Point(_Bv[0], _Bv[1]);
}
else
return _v;
}
function Rect(left, top, right, bottom)
{
this.left = left;
this.top = top;
this.right = right;
this.bottom = bottom;
this._A = _B;
}
function _Ce(_v)
{
if (typeof(_v) == "string")
{
_Bv = _v.split(",");
return new Rect(_Bv[0], _Bv[1], _Bv[2], _Bv[3]);
}
else
return _v;
}
function _B(_CY, _C0)
{
return (_CY >= this.left && _CY <= this.right && _C0 >= this.top && _C0 <= this.bottom)
}
function _F(_E, _G)
{
if (typeof(this[_E]) != "undefined")
eval("this."+_E+(_F.arguments.length == 2 ? "(_G)" : "()"));
}
function ObjectRef(_Bp)
{
_b = _Bp;
while (typeof(_b) == "string")
{
_b = _b.toUpperCase();
_b = eval(_b);
}
return _b;
}
function Mbedlet(name)
{
this.NAME = name;
_AI(this);
this._I = new Array();
this._J = new Array();
this._K = _i;
this._L = _j;
this._M = _k;
this._N = _l;
this._F = _F;
this.Service = _O;
this.Start = _P;
this._Q = _R;
this._S = _T;
this._U = _V;
this.MouseUp = _W;
this.MouseDown = _X;
this.MouseMove = _Y;
this.KeyDown = _CB;
this._Bx = _Bt;
this._Cu = _Cv;
this._DE = _DD;
this.GOTO = _Z;
this.PUT = _0
this.CALL = _1;
this._2 = null;
this._3 = null;
this._DJ = null;
this._DK = null;
this._DL = true;
this._CA = null;
this._DI = null;
this.StartServiceScript = Mbedlet_StartServiceScript;
this.StartServiceScript();
}
function _i(_5)
{
var _Bv;
for (_Bv=0;_Bv<this._I.length;_Bv++)
if (this._I[_Bv] == null)
break;
this._I[_Bv] = _5;
_5._6 = true;
_5._7 = 0;
}
function _j(_5)
{
var _Bv;
for (_Bv=0;_Bv<this._I.length;_Bv++)
{
if (this._I[_Bv] == _5)
{
this._I[_Bv]._6 = false;
this._I[_Bv] = null;
break;
}
}
}
function _P()
{
this._Cu();
if (this._CA == null)
{
_Ca = new Date();
this._8 = _Ca.getTime();
this._9 = 0;
setTimeout(this._DI, 25);
}
}
function _R()
{
this._F("ACTIVATE")
}
function _T()
{
this._F("DEACTIVATE")
}
function _X(_CY,_C0)
{
this._2 = this._U(_CY,_C0);
if (this._2)
return this._2.MouseDown(_CY,_C0);
this._F("MOUSEDOWN");
return false;
}
function _W(_CY,_C0)
{
if (this._2 != null)
{
this._2.MouseUp(_CY,_C0);
this._2 = null;
return false;
}
this._F("MOUSEUP");
return true;
}
function _Y(_CY,_C0)
{
this._DJ = _CY;
this._DK = _C0;
}
function _CB(_CY)
{
this._F("KEYPRESS", _CY);
return false;
}
function _Bt(_CY,_C0)
{
_d = this._U(_CY,_C0);
if (_d != null)
_d.MouseMove(_CY,_C0);
if (this._2 != null)
this._2.MouseMove(_CY,_C0)
if (_d != this._3)
{
if (this._3)
this._3._BB(_CY,_C0);
if (_d)
_d._Az(_CY,_C0);
this._3 = _d;
}
return true;
}
function _k(_e)
{
this._J[this._J.length] = _e;
}
function _l(_e)
{
var _Bv;
for (_Bv=0;_Bv<this._J.length;_Bv++)
{
if (this._J[_Bv] != _e && this._J[_Bv].TYPE == "RADIO" && this._J[_Bv].VALUE)
{
this._J[_Bv].FLIP(1);
this._J[_Bv].VALUE = false;
this._J[_Bv]._F("TOGGLEOFF")
this._J[_Bv]._f();
}
}
}
function _O(_9)
{
if (this._DL)
{
this._DL = false;
this._F("STARTUP");
}

if (_O.arguments.length == 1)
this._9 = _9;
else
{
_Ca = new Date();
this._9 = _Ca.getTime() - this._8;
}
if (this._DJ != null)
{
this._Bx(this._DJ,this._DK);
this._DJ = null;
this._DK = null;
}
var _Bv;
for (_Bv=0;_Bv < this._I.length;_Bv++)
{
if (this._I[_Bv] != null)
{
if (this._I[_Bv].Service(this._9) == false)
{
this._I[_Bv]._6 = false;
this._I[_Bv] = null;
}
}
}
if (this._CA == null)
{
setTimeout(this._DI,25);
}
}
function _Z(_g)
{
_h=_g.split(",")
if (_h.length == 1)
top.location = _g;
else
document.frames[_h[1]].src=_h[0];
}
function _0(_Bu)
{
window.status=_Bu;
}
function _1(_h)
{
eval(this.NAME + "_CALLBACK(_h)");
}
function _DD(_Bu)
{
return eval(_Bu);
}
function _AI(_5)
{
_5.Get = _C;
_5._m = _H;
_5._F = _F;
_5.ParentRef = _Bw;
_5.SET = _n;
_5.INCREMENT = _o;
_5.DECREMENT = _p;
_5.MULTIPLY = _q;
_5.DIVIDE = _r;
_5.RANDOMIZE = _s;
}
function _C(_4)
{
if (typeof(this[_4]) == "undefined")
{
if (typeof(MBEDLET[_4]) == "undefined")
return _4;
else
return MBEDLET[_4];
}
else
return this[_4];
}
function _H(_Bu, _t)
{
_Bu = _Bu.toUpperCase();
_h=_Bu.split(",")
_u = this.Get(_h[0])
if (_u != "NaN")
this.SET(_h[0],eval(_u.toString()+_t+_h[1]))
}
function _n(_4,_v)
{
this[_4] = _v;
}
function _o(_Bu)
{
this._m(_Bu,"+");
}
function _p(_Bu)
{
this._m(_Bu,"-");
}
function _q(_Bu)
{
this._m(_Bu,"*");
}
function _r(_Bu)
{
this._m(_Bu,"/");
}
function _s(_Bu)
{
_h=_Bu.split(",");
if (_h.length == 2)
_w = Math.floor(Math.random()*parseInt(_h[1]))+1;
else if (_h.length == 3)
_w = Math.floor(Math.random()*(parseInt(_h[2])-parseInt(_h[1])+1))+parseInt(_h[1]);
else
return;
this.SET(_h[0].toUpperCase(),_w);
}
function _AJ(_5)
{
_5.STOP = _x;
_5.PLAYFOREVER = false;
_5.PLAYCOUNT = 0;
_5._6 = false;
}
function _x()
{
MBEDLET._L(this);
}
function _DP(_C9, _AG)
{
var _AF=0.0;
if (this.CURVETYPE == "STRAIGHT" || this.CURVETYPE == "BEZIER")
{
_CY = this.STARTPOINT.h;
_C0 = this.STARTPOINT.v;
_CZ = this.ENDPOINT.h;
_C1 = this.ENDPOINT.v;
_C2 = _CZ-_CY;
_C3 = _C1-_C0;
if (_CY==_CZ && _C0==_C1)
{
_AG.h = _CY;
_AG.v = _C0;
}
else
{
_C8 = Math.sqrt(_C2*_C2 + _C3*_C3);
_C4 = (_C2*(_C9.h - _CY) + _C3*(_C9.v - _C0))/(_C8*_C8);
_C4 = Math.min(_C4,1);
_C4 = Math.max(_C4,0);
_AG.h = parseInt(_C2*_C4 + _CY);
_AG.v = parseInt(_C3*_C4 + _C0);
if (Math.max(_C2,-_C2) > Math.max(_C3,-_C3))
_AF = (_AG.h-_CY)/_C2;
else
_AF = (_AG.v-_C0)/_C3;
if (this.CURVETYPE == "BEZIER")
this._AQ(_AF, _AG);
}
}
else
{
if (_C9.h-this.CENTERPOINT.h == 0)
_C7 = 0;
else
_C7 = Math.atan((_C9.v-this.CENTERPOINT.v)/(_C9.h-this.CENTERPOINT.h));
_CI = Math.PI;
_CJ = _CI/2;
_CH = _CI * 2;
_AB = this._AB;
_AA = this._AA;
_CD = this.STARTPOINT.h;
_CE = this.STARTPOINT.v;
_C5 = this.ENDPOINT.h;
_C6 = this.ENDPOINT.v;
if (this._AC)
{
if (_AB < _CJ)
{
if (_C7 < -_CJ || (_C7 < 0 && _AB > 0))
_C7 += _CH;
}
else if (_C7 < _CJ)
_C7 += _CH;
}
if ((_C7 > Math.max(_AB, _AA) || _C7 < Math.min(_AB, _AA)))
{
_CK = Math.sqrt((_C9.h - _CD) * (_C9.h - _CD) +
 (_C9.v - _CE) * (_C9.v - _CE));
_CL = Math.sqrt((_C9.h - _C5) * (_C9.h - _C5) +
       (_C9.v - _C6) * (_C9.v - _C6));
if (_CK < _CL)
{
_AG.h = _CD;
_AG.v = _CE;
_AF = 0.0;
}
else
{
_AG.h = _C5;
_AG.v = _C6;
_AF = 1.0;
}
}
else
{
_AG.h = parseInt(this.RADIUS*Math.cos(_C7) + this.CENTERPOINT.h + .5);
_AG.v = parseInt(this.RADIUS*Math.sin(_C7) + this.CENTERPOINT.v + .5);
_AF = (_C7 - _AB)/(_AA - _AB);
}
}
return _AF;
}
function _y()
{
if (this.STARTPOINT.h == this.ENDPOINT.h && this.STARTPOINT.v == this.ENDPOINT.v)
{
this.RADIUS = Math.floor(Math.sqrt((this.STARTPOINT.h - this.CENTERPOINT.h) * (this.STARTPOINT.h - this.CENTERPOINT.h) +
 (this.STARTPOINT.v - this.CENTERPOINT.v) * (this.STARTPOINT.v - this.CENTERPOINT.v)));
this._AB = Math.atan2(this.STARTPOINT.v - this.CENTERPOINT.v, this.STARTPOINT.h - this.CENTERPOINT.h);
_z = this.CLOCKWISE ? 1 : -1;
this._AA = this._AB +  _z*2*Math.PI;
this._AC = false;
}
else
{
_z = this.CONCAVE ? (this.CLOCKWISE ? 1 : -1) : (this.CLOCKWISE ? -1 : 1);
_Ca = Math.sqrt((this.STARTPOINT.h - this.ENDPOINT.h) * (this.STARTPOINT.h - this.ENDPOINT.h) +
 (this.STARTPOINT.v - this.ENDPOINT.v) * (this.STARTPOINT.v - this.ENDPOINT.v));
d2 = Math.sqrt(this.RADIUS * this.RADIUS - _Ca*_Ca/4);
_AD = Math.atan2(this.STARTPOINT.v - this.ENDPOINT.v, this.STARTPOINT.h - this.ENDPOINT.h);
this.CENTERPOINT.h = (this.STARTPOINT.h + this.ENDPOINT.h)/2 - _z*d2*Math.sin(_AD);
this.CENTERPOINT.v = (this.STARTPOINT.v + this.ENDPOINT.v)/2 + _z*d2*Math.cos(_AD);
this._AB = Math.atan2(this.STARTPOINT.v - this.CENTERPOINT.v, this.STARTPOINT.h - this.CENTERPOINT.h);
this._AA = Math.atan2(this.ENDPOINT.v - this.CENTERPOINT.v, this.ENDPOINT.h - this.CENTERPOINT.h);
if (this.CLOCKWISE && this._AB > this._AA)
{
this._AA += 2*Math.PI;
this._AC = true;
}
else if (!this.CLOCKWISE && this._AB < this._AA)
{
this._AB += 2*Math.PI;
this._AC = true;
}
else
this._AC = false;
}
this._AE = false;
}
function _AR(_AF,_AG)
{
if (this.CURVETYPE == "STRAIGHT")
{
_AG.h = this.STARTPOINT.h + _AF * (this.ENDPOINT.h - this.STARTPOINT.h)
_AG.v = this.STARTPOINT.v + _AF * (this.ENDPOINT.v - this.STARTPOINT.v)
}
else if (this.CURVETYPE == "BEZIER")
{
if (this.CONTROLPOINT2.h == -1)
{
_CU = (1 - _AF) * (1 - _AF);
_CV = 2 * _AF * (1 - _AF);
_CW = _AF * _AF;

_AG.h = Math.floor(_CU*this.STARTPOINT.h + _CV*this.CONTROLPOINT1.h + _CW*this.ENDPOINT.h + .5);
_AG.v = Math.floor(_CU*this.STARTPOINT.v + _CV*this.CONTROLPOINT1.v + _CW*this.ENDPOINT.v + .5);
} 
else 
{
_CU = (1 - _AF) * (1 - _AF)*(1 - _AF);
_CV = 3 * _AF * (1 - _AF) * (1 - _AF);
_CW = 3 * _AF * _AF * (1 - _AF);
_CX = _AF * _AF * _AF;

_AG.h = Math.floor(_CU*this.STARTPOINT.h + _CV*this.CONTROLPOINT1.h +
  _CW*this.CONTROLPOINT2.h + _CX*this.ENDPOINT.h + .5);
_AG.v = Math.floor(_CU*this.STARTPOINT.v + _CV*this.CONTROLPOINT1.v +
  _CW*this.CONTROLPOINT2.v + _CX*this.ENDPOINT.v + .5);
}
}
else if (this.CURVETYPE == "CIRCULAR")
{
_AH = (this._AA - this._AB)*_AF + this._AB;
_AG.h = Math.floor(this.RADIUS*Math.cos(_AH) + this.CENTERPOINT.h + .5);
_AG.v = Math.floor(this.RADIUS*Math.sin(_AH) + this.CENTERPOINT.v + .5);
}
}

function PATH(name)
{
this.NAME = name
_AI(this);
_AJ(this);
this.EASEIN = 0;
this.EASEOUT = 0;
this.DURATION = 1000;
this.AUTOREVERSE=false
this.SET=_AK;
this.Start = _AL;
this.Service = _AM;
this.PLAY = _AN;
this.RESET = _AO;
this.CURVETYPE = "STRAIGHT"
this.STARTPOINT = new Point(-1,-1)
this._AP = true
this.ENDPOINT = new Point(100,100)
this.CONTROLPOINT1 = new Point(0,100)
this.CONTROLPOINT2 = new Point(-1,-1)
this.CENTERPOINT = new Point(0,0)
this.CLOCKWISE = true;
this.CONCAVE = false;
this.RADIUS = 100;
this._AQ = _AR;
this._AS = _y;
this._AE = true;
}
function _AL()
{
this._8 = MBEDLET._9;
this._AT=false
if (this.STARTPOINT.h == -1)
this._AP = false;
if (!this._AP)
{
_AU = this._AV.Get("LOCATION")
this.STARTPOINT.h = _AU.h;
this.STARTPOINT.v = _AU.v;
}
else
this._AV._AW(this.STARTPOINT.h,this.STARTPOINT.v)
this._AV._Ap(true);
if (typeof(eval("this._AV.FLIPINTERVAL")) != "undefined")
this._AY = this._AV.FLIPINTERVAL;
else
this._AY = 0;
this._AZ = this._8;
if (this.CURVETYPE == "CIRCULAR" & this._AE)
this._AS();
}
function _AM(_9)
{
if (this._AY && (_9 - this._AZ >= this._AY))
{
this._AV.FORWARD(true);
this._AZ = _9;
}
_AF = (_9 - this._8)/this.DURATION;
if (_AF > 1.0) _AF = 1.0;
if (this.EASEIN || this.EASEOUT)
{
_A0 = this.EASEIN/100;
_A1 = this.EASEOUT/100;
v = 1/(1-(_A0+_A1)/2);
if (_AF < _A0 && _A0 > 0)
_AF = _AF * _AF * v / (2 * _A0);
else if (_AF < 1-_A1 || _A1 == 0)
_AF = (_AF - _A0 / 2) * v;
else 
_AF = 1 - (1 - _AF) * (1 - _AF) * v / (2 * _A1);
}
if (this._AT)
_AF=1-_AF;
_A2 = new Point(0,0)
this._AQ(_AF,_A2);
this._AV._AW(_A2.h,_A2.v)
if ((!this._AT && _AF < 1.0) || (this._AT && _AF > 0))
return true;
else
{
if (!this._AT && this.AUTOREVERSE)
{
this._8 = _9;
 this._AT = true;
return true;
}
if (this.PLAYFOREVER || (this.PLAYCOUNT && (++this._7 < this.PLAYCOUNT)))
{
this.Start()
return true;
}
return false;
}
}
function _AK(_4,_v)
{
this[_4] = _v;
if (this.CURVETYPE == "CIRCULAR")
{
if (_4 == "RADIUS" || _4 == "STARTPOINT" || _4 == "ENDPOINT" ||
    _4 == "CENTERPOINT" || _4 == "CLOCKWISE" || _4 == "CONCAVE")
this._AE == true;
}
if (_4 == "STARTPOINT")
this._AP = true;
}
function _AN(_5)
{
if (_AN.arguments.length == 0) 
this._AV=eval(this.PLAYER);
else
this._AV=eval(_5.toUpperCase());
if (!this._6)
MBEDLET._K(this);
this.Start()
}
function _AO(_5)
{
if (_AO.arguments.length == 0) 
this._AV=eval(this.PLAYER);
else
this._AV=eval(_5.toUpperCase());
this.Start()
}

function SOUND(name)
{
this.NAME = name;
_AI(this);
_AJ(this)
this.PLAY = _A4
this.Service = _A5
}
function EFFECT(name)
{
this.NAME = name;
_AI(this);
this.TYPE = "WIPE";
this.DIRECTION = "LEFT";
this.DURATION = 1000;
this.Play = _A6;
this.Service = _A7;
this._A9 = _A8;
this._6 = false;
}
function SCORE(name)
{
this.NAME = name
_AI(this);
_AJ(this);
this.frames = new Array();
this.PLAY = _Af;
this.WAIT = _Ag;
this.END = _Ah;
this.Service = _Ai;
this.PARAM = ""
}
function _Ai(_9)
{
if (this._Aj)
{
if (this._Aj._6)
return true;
this._8 = _9-this.frames[this._Ak];
this._Aj = null;
}
while (this._Ak < this.frames.length && (_9-this._8) >= this.frames[this._Ak] && this._Aj == null)
{
this.DoScoreLine(this._Ak);
this._Ak++
}
if (this._Ak >= this.frames.length)
{
if (this.PLAYFOREVER || (this.PLAYCOUNT && (++this._7 < this.PLAYCOUNT)))
{
this.PLAY();
return true;
}
else
return false;
}
else
return true;
}
function _Af(_G)
{
if (_Af.arguments.length == 1) 
this.PARAM = _G
if (!this._6)
MBEDLET._K(this);
this._Ak = 0;
this._8 = MBEDLET._9;
this._Aj = null;
}
function _Ag(_Al)
{
this._Aj = eval(_Al.toUpperCase())
}
function _Ah()
{
}
function _BJ(_5)
{
_5.REGPOINT = new Point(0,0);
_5.MOVE = _Am;
_5._AW = _An;
_5.OSDSetLocation = Visible_OSDSetLocation;
_5._Ap = _Ao;
_5.GetVisible = Visible_GetVisible;
_5.GetRect = Visible_GetRect;
_5.Get = _Aq;
_5.SET = _Ar;
_5.SHOW = _As;
_5.HIDE = _At;
_5.ABOVE = _Au;
_5.BELOW = _Av;
_5.MouseDown = _Aw;
_5.MouseUp = _Ax;
_5._Az = _Ay;
_5._BB = _BA;
_5.MouseMove = _BC;
_5.DRAGGABLE = false;
_5.DRAGRECT = new Rect(0,0,320,240);
_5.NOMESSAGES = false;
_5._BD = false;
_5._BE = new Point(0,0);
_5._CC = null;
}
function _Aw(_CY,_C0)
{
this._BD = true;
this._BF = true;
this._F("MOUSEDOWN");
if (this.DRAGGABLE)
{
rect = this.GetRect();
this._BE.h = _CY-rect.left-(rect.right-rect.left)*this.REGPOINT.h/100;
this._BE.v = _C0-rect.top-(rect.bottom-rect.top)*this.REGPOINT.v/100;
}
return false;
}
function _BC(_CY,_C0)
{
if (this.DRAGGABLE && this._BD)
{
_CY -= this._BE.h;
_C0 -= this._BE.v;
_Cg = Math.min(Math.max(_CY, this.DRAGRECT.left),this.DRAGRECT.right);
_Ch = Math.min(Math.max(_C0, this.DRAGRECT.top),this.DRAGRECT.bottom);
this._AW(_Cg,_Ch);
}
return false;
}
function _Ax(_CY,_C0)
{
this._F("MOUSERELEASE");
if (this._BF)
this._F("MOUSEUP");
else
this._F("MOUSELEAVE");
if (this.DRAGGABLE)
{
_BG = MBEDLET._U(_CY,_C0,this);
if (_BG)
_BG._F("DROPPEDON",_BG)
}
this._BD = false;
return false;
}
function _Ay()
{
this._BF=true;
if (!this._BD)
this._F("MOUSEENTER");
return false;
}
function _BA()
{
this._BF=false;
if (!this._BD)
this._F("MOUSELEAVE");
return false;
}
function _An(_CY,_C0)
{
if (this.REGPOINT.h || this.REGPOINT.v)
{
rect = this.GetRect();
_CY -= (rect.right-rect.left)*this.REGPOINT.h/100;
_C0 -= (rect.bottom-rect.top)*this.REGPOINT.v/100;
}
this.OSDSetLocation(_CY,_C0);
}
function _Aq(_4)
{
if (_4 == "VISIBLE")
return this.GetVisible();
else if (_4 == "LOCATION")
{
rect = this.GetRect();
_CY = rect.left;
_C0 = rect.top;
if (this.REGPOINT.h || this.REGPOINT.v)
{
_CY += (rect.right-rect.left)*this.REGPOINT.h/100;
_C0 += (rect.bottom-rect.top)*this.REGPOINT.v/100;
}
return new Point(_CY,_C0);
}
else
{
if (typeof(this[_4]) == "undefined")
{
if (typeof(MBEDLET[_4]) == "undefined")
return _4;
else
return MBEDLET[_4];
}
else
return this[_4];
}
}

function _Ar(_4, _v)
{
if (_4 == "VISIBLE")
this._Ap(_v);
else if (_4 == "LOCATION")
{
_v = _Cd(_v);
this._AW(_v.h, _v.v);
}
else
this[_4] = _v;
}
function _Am(pt)
{
pt = _Cd(pt);
this._AW(pt.h,pt.v)
}
function _As(_BH)
{
if (_As.arguments.length == 0)
this._Ap(true);
else
eval(_BH.toUpperCase()).Play(this,true);
}
function _At(_BH)
{
if (_At.arguments.length == 0)
this._Ap(false);
else
eval(_BH.toUpperCase()).Play(this,false);
}
function BOX(name)
{
this.NAME = name;
_AI(this);
_BJ(this);
this.LINECOLOR = "#000000";
this.LINESIZE = 1;
this.FILLCOLOR = "#000000";
this.FILLED = true;
}
function PICTURE(name)
{
this.NAME = name;
_AI(this);
_BJ(this);
this.LOAD = _BK;
this.CLEAR = _BL;
this.TILED = false;
}
function SUBLET(name)
{
this.NAME = name;
_AI(this);
_BJ(this);
this.LOAD = _BM;
this.CLEAR = _BN;
this.MouseDown = _Bq;
this.MouseUp = _Br;
this.MouseMove = _Bs;
this.Service = _Bz;
this._Ct = _DF;
this.GetChild = _DG;
MBEDLET._K(this);
}
function AUDIOSTREAM(name)
{
this.NAME = name;
_AI(this);
_AJ(this);
this._BY = false;
this.PLAY = _BO;
this.STOP = _BP;
this.PAUSE = _BQ;
this.LOAD = _BR;
this.CLEAR = _BS;
this._BT = _BU;
this._BV = _BW;
this._Ct = _Cj;
}
function SPRITE(name)
{
this.NAME = name;
_AI(this);
_BJ(this);
_AJ(this);
this.Service = _BZ;
this._B0 = _Ar;
this.FLIP = _B1;
this.FORWARD = _B2;
this.BACK = _DM;
this.PLAY = _B3;
this.FLIPINDEX = 1;
this.FLIPINTERVAL=200;
this.SET = _B4;
this._Ct = _Cw;
}
function _B3()
{
if (!this._6)
MBEDLET._K(this);
this._AZ = MBEDLET._9;
}
function _B4(_4,_v)
{
if (_4 == "FLIPINDEX")
this.FLIP(_v);
else
this._B0(_4,_v);
}
function BUTTON(name)
{
this.NAME = name;
_AI(this);
_BJ(this)
this.MouseDown = _B7;
this.MouseUp = _B8;
this._Az = _B9;
this._BB = _Ba;
this._Bc = _Aw;
this._Bd = _Ax;
this._Be = _Ay;
this._Bf = _BA;
this._f = _Bb;
this._Ct = _Cw;
this.FLIP = _B1;
this.FORWARD = _B2;
this.BACK = _DM;
this.MOUSEOVER = false;
this.FLIPINDEX = 1;
this.TYPE = "PUSH";
this.PLAYER="";
this.ONVALUE=true;
this.OFFVALUE=false;
this.VALUE=false;
MBEDLET._M(this);
}
function _Bb()
{
if (this.PLAYER != "")
eval(this.PLAYER).SET(this.PROPERTY,this.VALUE ? this.ONVALUE : this.OFFVALUE);
}
function _B7(_CY,_C0)
{
this._Bo = this.VALUE
this.VALUE = (this.TYPE == "CHECKBOX") ? !this._Bo : true
this.FLIP(this.VALUE ? 2 : 1);
return this._Bc(_CY,_C0);
}
function _B8(_CY,_C0)
{
if (this.TYPE == "PUSH")
{
this.FLIP(1);
this.VALUE = false;
}
else 
{
if (this._BF && this.VALUE != this._Bo)
{
if (this.TYPE == "RADIO")
MBEDLET._N(this);
if (this.VALUE)
this._F("TOGGLEON");
else
this._F("TOGGLEOFF");
this._f();
}
this.FLIP(this.VALUE ? 2 : 1);
}
return this._Bd(_CY,_C0);
}
function _B9(_CY,_C0)
{
if (this._BD)
{
this.VALUE = (this.TYPE == "CHECKBOX") ? !this._Bo : true;
this.FLIP(this.VALUE ? 2 : 1);
}
else if (this.MOUSEOVER && (this.TYPE == "PUSH" || !this.VALUE))
this.FLIP(3);
return this._Be(_CY,_C0);
}

function _Ba(_CY,_C0)
{
if (this._BD)
{
this.VALUE = this._Bo;
this.FLIP(this.VALUE ? 2 : 1);
}
else if (this.MOUSEOVER && (this.TYPE == "PUSH" || !this.VALUE))
this.FLIP(1);
return this._Bf(_CY,_C0);
}
function TEXT(name)
{
this.NAME = name;
_AI(this);
_BJ(this)
this.SET = _Bg;
this.LOAD = _Bh;
this.CLEAR = _Bi;
this.APPEND = _Bj;
this._B0 = _Ar;
this._Bk = _Bl;
this.SERIF = false;
this.FONTSIZE=12;
this.BOLD=false;
this.ITALIC=false;
this.JUSTIFY="LEFT"
this.COLOR="#000000"
this.VALUE = "";
}
function _Bg(_4,_v)
{
this._B0(_4,_v);
if (_4 != "LOCATION" && _4 != "VISIBLE")
this._Bk();
}
function _Bh(_g)
{
document.layers[this.NAME+"Layer"].src=_g
this.VALUE = "";
}
function _Bi(_g)
{
this.VALUE = "";
this._Bk();
}
function _Bj(_Bu)
{
this.VALUE += _Bu;
this._Bk();
}
function CONTROL(name)
{
this.NAME = name;
_AI(this);
_BJ(this)
this.MouseDown = _CM;
this.MouseUp = _CN;
this.MouseMove = _CO;
this._Bc = _Aw;
this._Bd = _Ax;
this.VisibleMouseMove = _BC;
this._f = _CP;
this._CR = _CQ;
this._Ct = _Cw;
this.FLIP = _B1;
this.FORWARD = _B2;
this.BACK = _DM;
this.UPDATE = _DN;
this.SYNCHRONIZE = _DO;
this.SET=Control_SET;
this._BE = new Point(0,0);
this.MIN = 0;
this.MIN2 = 0;
this.MAX = 100;
this.MAX2 = 100;
this.VALUE = 0;
this.VALUE2 = 0;
this.PLAYER = "";
this.PROPERTY = "";
this.CONTINUOUS = false;
this.STEPSIZE = 1;
this.AUTOHIDE = false;
this.SNAPTOVALUE = false;
this.TYPE = "SLIDER";
this.CURVETYPE = "STRAIGHT"
this.STARTPOINT = new Point(-1,-1)
this.ENDPOINT = new Point(100,100)
this.CONTROLPOINT1 = new Point(0,100)
this.CONTROLPOINT2 = new Point(-1,-1)
this.CENTERPOINT = new Point(0,0)
this.CLOCKWISE = true;
this.CONCAVE = false;
this.RADIUS = 100;
this._AQ = _AR;
this._AS = _y;
this.ClosestPoint = _DP;
this._AE = true;
}
function _CP()
{
if (this.PLAYER != "")
eval(this.PLAYER).SET(this.PROPERTY,this.VALUE);
}
function _CQ()
{
_CT = this.MAX;
_CS = this.MIN;
_v  = this.VALUE;
if (_CT == _CS)
_AF = 0;
else
_AF = (_v - _CS)/(_CT - _CS);
_A2 = new Point(0,0);
this._AQ(_AF,_A2);
this._AW(_A2.h,_A2.v);
}
function _CM(_CY,_C0)
{
if (this.CURVETYPE == "CIRCULAR" & this._AE)
this._AS();
rect = this.GetRect();
this._BE.h = _CY-rect.left-(rect.right-rect.left)*this.REGPOINT.h/100;
this._BE.v = _C0-rect.top-(rect.bottom-rect.top)*this.REGPOINT.v/100;
return this._Bc(_CY,_C0);
}
function _CN(_CY,_C0)
{
this._f();
return this._Bd(_CY,_C0);
}
function _CO(_CY,_C0)
{
if (this._BD)
{
_Cb = new Point(_CY-this._BE.h, _C0-this._BE.v);
_Cc = new Point(0,0);
_AF = this.ClosestPoint(_Cb, _Cc);
_Bv = (this.MIN + _AF*(this.MAX-this.MIN))/this.STEPSIZE;
if (_Bv>0)
_Bv+=.5
else if (_Bv<0)
_Bv-=.5;
this.VALUE = parseInt(_Bv) * this.STEPSIZE;
if (this.SNAPTOVALUE)
this._CR();
else
this._AW(_Cc.h, _Cc.v);
if (this.CONTINUOUS)
this._f();
return true;
}
else
return this._Bd(_CY,_C0);
}
function _DN()
{
this._f();
}
function _DO()
{
if (this.PLAYER != "")
{
_CY = eval(this.PLAYER+"."+this.PROPERTY);
this.VALUE = parseInt(_CY/this.STEPSIZE)*this.STEPSIZE;
this._CR();
}
}
function Control_SET(_4,_v)
{
this[_4] = _v;
if (this.CURVETYPE == "CIRCULAR")
{
if (_4 == "RADIUS" || _4 == "STARTPOINT" || _4 == "ENDPOINT" ||
    _4 == "CENTERPOINT" || _4 == "CLOCKWISE" || _4 == "CONCAVE")
this._AE == true;
}
}

