﻿document.write('<style type="text/css">');
document.write('#idQuckBar .textActiveX01 {font-family: Tahoma;font-size: 12px;font-weight: normal;color: #666666;text-decoration: none;}');
document.write('#idQuckBar .textActiveX01:hover {color: #666666;text-decoration: underline;}');	
document.write('#idQuckBar .textActiveX01:link {color: #666666;}');	
document.write('#idQuckBar .textActiveX01:active {color: #666666;}');	
document.write('#idQuckBar .textActiveX01:visited {color: #666666;}');
document.write('#idQuckBar img{border:0px;display:block;}');
document.write('.imgOpacity60:hover input, .imgOpacity60:hover img, .overImgOpa60:hover{ opacity:0.6; filter:alpha(opacity=60);}');
document.write('#boxQuickBar{width:74px;height: 37px;position: absolute;overflow: hidden; margin:-15px 0 0 -80px;');
document.write('</style>');

document.write('<div id="idQuckBar">');
document.write('<table width="100%" border="0" cellspacing="0" cellpadding="0">');
document.write('<tr>');
document.write('<td height="37" background="images/QuickBar_bg.gif"><table width="100%" border="0" cellpadding="0" cellspacing="0">');
document.write('<tr>');
/*XMas2010*/
/*XMas2010*/
document.write('<td id="menu_parent0" width="99" height="37" align="left" background="QuickBar_bg.gif"><a class="imgOpacity60"  target="_blank" href="http://www.reborn-ran.com/"><img src="images/topbar-ran.jpg" width="110" height="37" border="0" /></a></td>');
document.write('<td id="menu_parent1" width="99" align="left" background="QuickBar_bg.gif"><a class="imgOpacity60"  target="_blank" href="http://gunz.reborn-ran.com/"><img src="images/topbar-gunz.jpg" width="110" height="37" border="0" align="left" /></a></td>');
document.write('<td id="menu_parent2" width="99" align="left" background="QuickBar_bg.gif"><a class="imgOpacity60"  target="_blank" href="http://www.reborn-ran.com/"><img src="images/topbar-mu.jpg" width="110" height="37" border="0" align="left" /></a></td>');
document.write('<td id="menu_parent3" width="99" align="left" background="QuickBar_bg.gif"><a class="imgOpacity60"  target="_blank" href="http://www.reborn-ran.com/"><img src="images/topbar-GB.jpg" width="110" height="37" align="left" /></a></td>');
document.write('<td id="menu_parent4" width="99" align="left" background="QuickBar_bg.gif"><a class="imgOpacity60"  target="_blank" href="http://www.reborn-ran.com/"><img src="images/topbar-maple.jpg" width="110" height="37" align="left" /></a></td>');
/*XMas2010*/
/*XMas2010*/
document.write('<td align="right"><table width="215" border="0" cellpadding="0" cellspacing="0">');
document.write('<tr>');
document.write('<td id="menu_parent6" align="center"></td>');
document.write('<td align="center"></td>');
document.write('<td id="menu_parent7" align="right"><div id="boxQuickBar"><img src="images/Quickbar_10.gif" id="QuickMenu" style="margin-left: 80px"/></div></td>');
document.write('</tr>');
document.write('</table></td>');
document.write('</tr>');
document.write('</table></td>');
document.write('</tr>');
document.write('</table>');

//submenu0
document.write('<div style="z-index:10000" id="menu_child0">');
document.write('<TABLE cellSpacing=0 cellPadding=0 width=152 border=0>');
document.write('<TR>');
document.write('<TD width=10><IMG height=15 alt="" src="images/QuickBar_bgtext_01.png" width=9 /></TD><TD width=205 background="images/QuickBar_bgtext_02.png" height=15><IMG height=1 src="images/spacer.gif" width=1 /></TD>');
document.write('<TD><IMG height=15 alt="" src="images/QuickBar_bgtext_04.png" width=9 /></TD>');
document.write('</TR>');
document.write('<TR>');
document.write('<TD background="images/QuickBar_bgtext_05.png"> </TD>');
document.write('<TD align=right bgColor=#ffffff>');
document.write('<a href="http://www.reborn-ran.com/" target="_blank" class="imgOpacity70" ><IMG height=61 src="images/topbar-ran-over.jpg" width=134 border="0"/></a>');
document.write('<TABLE cellSpacing=0 cellPadding=0 width="134" align=center border=0>');
document.write('<tr>');
document.write('<td align="center" colspan="2" height="10">');
document.write('</td>');
document.write('</tr>');
document.write('<TR>');
document.write('<TD height="20" align=center width="11%"><IMG height=11 src="images/QuickBar_point.jpg" width=9 /></TD>');
document.write('<TD height="20" align=left width="89%"><a target="_blank" class="textActiveX01" href="http://www.reborn-ran.com/register.php">สมัครสมาชิก</a> </TD></TR><TR><TD align=center><IMG height=11 src="images/QuickBar_point.jpg" width=9 /></TD>');
document.write('<TD height="20" align=left><a target="_blank"  class="textActiveX01" href="http://www.reborn-ran.com/download.php">Download Center</a></TD></TR><TR><TD align=center><IMG height=11 src="images/QuickBar_point.jpg" width=9 /></TD>');
document.write('<TD height="20" align=left><a target="_blank"  class="textActiveX01" href="http://www.reborn-ran.com/help.php">แนะนำการเล่น</a></TD></TR><TR><TD align=center><IMG height=11 src="images/QuickBar_point.jpg" width=9 /></TD>');
document.write('<TD height="20" align=left><a target="_blank"  class="textActiveX01" href="http://www.reborn-ran.com/"><b>เข้าสู่เว็บไซต์</b></a></TD>');
document.write('</TR>');
document.write('</TABLE>');
document.write('<IMG height=21 src="images/QuickBar_rateAllCmr.jpg" width=18 /></TD><TD width=9 background="images/QuickBar_bgtext_07.png"> </TD>');
document.write('</TR>');
document.write('<TR>');
document.write('<TD><IMG height=9 alt="" src="images/QuickBar_bgtext_08.png" width=9 /></TD>');
document.write('<TD background="images/QuickBar_bgtext_09.png"><IMG height=1 src="spacer.gif" width=1 /></TD>');
document.write('<TD><IMG height=9 alt="" src="images/QuickBar_bgtext_10.png" width=9 /></TD>');
document.write('</TR>');
document.write('</TABLE>');
document.write('</div>');

//submenu1
document.write('<div id="menu_child1">');
document.write('<TABLE cellSpacing=0 cellPadding=0 width=152 border=0>');
document.write('<TR>');
document.write('<TD width=10><IMG height=15 alt="" src="images/QuickBar_bgtext_01.png" width=9 /></TD><TD width=205 background="images/QuickBar_bgtext_02.png" height=15><IMG height=1 src="images/spacer.gif" width=1 /></TD>');
document.write('<TD><IMG height=15 alt="" src="images/QuickBar_bgtext_04.png" width=9 /></TD>');
document.write('</TR>');
document.write('<TR>');
document.write('<TD background="images/QuickBar_bgtext_05.png"> </TD>');
document.write('<TD align=right bgColor=#ffffff><a href="http://gunz.reborn-ran.com/" target="_blank" class="imgOpacity70" ><IMG height=61 src="images/topbar-gunz-over.jpg" width=134 border="0"/></a>');
document.write('<TABLE cellSpacing=0 cellPadding=0 width="100%" align=center border=0>');
document.write('<tr>');
document.write('<td align="center" colspan="2" height="10">');
document.write('</td>');
document.write('</tr>');
document.write('<TR>');
document.write('<TD height="20" align=center width="11%"><IMG height=11 src="images/QuickBar_point.jpg" width=9 /></TD>');
document.write('<TD height="20" align=left width="89%"><a target="_blank" class="textActiveX01" href="http://gunz.reborn-ran.com/index.php?gunz=register">สมัครสมาชิก</a> </TD></TR><TR><TD align=center><IMG height=11 src="images/QuickBar_point.jpg" width=9 /></TD>');
document.write('<TD height="20" align=left><a target="_blank"  class="textActiveX01" href="http://gunz.reborn-ran.com/index.php?gunz=download">Download Center</a></TD></TR><TR><TD align=center><IMG height=11 src="images/QuickBar_point.jpg" width=9 /></TD>');
document.write('<TD height="20" align=left><a target="_blank"  class="textActiveX01" href="http://gunz.reborn-ran.com/index.php?gunz=basiccontrol">แนะนำการเล่น</a></TD></TR><TR><TD align=center><IMG height=11 src="images/QuickBar_point.jpg" width=9 /></TD>');
document.write('<TD height="20" align=left><a target="_blank"  class="textActiveX01" href="http://gunz.reborn-ran.com/"><b>เข้าสู่เว็บไซต์</b></a></TD>');
document.write('</TR>');
document.write('</TABLE>');
document.write('<IMG height=21 src="images/QuickBar_rate15L2.jpg" width=18 /></TD><TD width=9 background="images/QuickBar_bgtext_07.png"> </TD>');
document.write('</TR>');
document.write('<TR>');
document.write('<TD><IMG height=9 alt="" src="images/QuickBar_bgtext_08.png" width=9 /></TD>');
document.write('<TD background="images/QuickBar_bgtext_09.png"><IMG height=1 src="spacer.gif" width=1 /></TD>');
document.write('<TD><IMG height=9 alt="" src="images/QuickBar_bgtext_10.png" width=9 /></TD>');
document.write('</TR>');
document.write('</TABLE>');
document.write('</div>');

//submenu2
document.write('<div id="menu_child2">');
document.write('<table border="0" cellpadding="0" cellspacing="0" width="152">');
document.write('<tr>');
document.write('<td width="10"><img alt="" height="15" src="images/QuickBar_bgtext_01.png" width="9" /></td>');
document.write('<td background="images/QuickBar_bgtext_02.png" height="15" width="205"><img height="1" src="images/spacer.gif" width="1" /></td><td>');
document.write('<img alt="" height="15" src="images/QuickBar_bgtext_04.png" width="9" /></td>');
document.write('</tr>');
document.write('<tr>');
document.write('<td background="images/QuickBar_bgtext_05.png">&nbsp;</td>');
document.write('<td align="right" bgcolor="#ffffff"><a href="http://www.reborn-ran.com/" target="_blank" class="imgOpacity70" ><img height="61" src="images/topbar-mu-over.jpg" width="134" /></a>');
document.write('<table align="center" border="0" cellpadding="0" cellspacing="0" width="100%">');

document.write('<tr>');
document.write('<td align="center" colspan="2" height="10">');
document.write('</td>');
document.write('</tr>');
document.write('<TR>');

document.write('</TR>');

document.write('</table>');
document.write('<img height="21" src="images/QuickBar_rateAllCmr.jpg" width="18" /></td>');
document.write('<td background="images/QuickBar_bgtext_07.png" width="9">&nbsp;</td>');
document.write('</tr>');
document.write('<tr>');
document.write('<td><img alt="" height="9" src="images/QuickBar_bgtext_08.png" width="9" /></td>');
document.write('<td background="images/QuickBar_bgtext_09.png"><img height="1" src="spacer.gif" width="1" /></td>');
document.write('<td>');
document.write('<img alt="" height="9" src="images/QuickBar_bgtext_10.png" width="9" /></td></tr>');
document.write('</table>');
document.write('</div>');

//submenu3
document.write('<div id="menu_child3">');
document.write('<TABLE cellSpacing=0 cellPadding=0 width=152 border=0>');
document.write('<TR>');
document.write('<TD width=10><IMG height=15 alt="" src="images/QuickBar_bgtext_01.png" width=9 /></TD>');
document.write('<TD width=205 background="images/QuickBar_bgtext_02.png" height=15><IMG height=1 src="images/spacer.gif" width=1 /></TD><TD><IMG height=15 alt="" src="images/QuickBar_bgtext_04.png" width=9 /></TD>');
document.write('</TR>');
document.write('<TR>');
document.write('<TD background="images/QuickBar_bgtext_05.png"> </TD><TD align=right bgColor=#ffffff><a href="http://www.reborn-ran.com/" target="_blank" class="imgOpacity70" ><IMG height=61 src="images/topbar-GB-over.jpg" width=134 /></a> ');
document.write('<TABLE cellSpacing=0 cellPadding=0 width="100%" align=center border=0>');

document.write('<tr>');
document.write('<td align="center" colspan="2" height="10">');
document.write('</td>');
document.write('</tr>');
document.write('<TR>');

document.write('</TR>');

document.write('</TABLE>');
document.write('<IMG height=21 src="images/QuickBar_rateAllCmr.jpg" width=18 /></TD>');
document.write('<TD width=9 background="images/QuickBar_bgtext_07.png"> </TD>');
document.write('</TR>');
document.write('<TR>');
document.write('<TD><IMG height=9 alt="" src="images/QuickBar_bgtext_08.png" width=9 /></TD>');
document.write('<TD background="images/QuickBar_bgtext_09.png"><IMG height=1 src="spacer.gif" width=1 /></TD>');
document.write('<TD><IMG height=9 alt="" src="images/QuickBar_bgtext_10.png" width=9 /></TD>');
document.write('</TR>');
document.write('</TABLE>');
document.write('</div>');

//submenu4
document.write('<div id="menu_child4">');
document.write('<TABLE cellSpacing=0 cellPadding=0 width=152 border=0>');
document.write('<TR>');
document.write('<TD width=10><IMG height=15 alt="" src="images/QuickBar_bgtext_01.png" width=9 /></TD>');
document.write('<TD width=205 background="images/QuickBar_bgtext_02.png" height=15><IMG height=1 src="images/spacer.gif" width=1 /></TD><TD><IMG height=15 alt="" src="images/QuickBar_bgtext_04.png" width=9 /></TD>');
document.write('</TR>');
document.write('<TR>');
document.write('<TD background="images/QuickBar_bgtext_05.png"> </TD>');
document.write('<TD align=right bgColor=#ffffff><a href="http://www.reborn-ran.com/" target="_blank" class="imgOpacity70" ><IMG height=61 src="images/topbar-maple-over.jpg" width=134 /></a>');
document.write('<TABLE cellSpacing=0 cellPadding=0 width="100%" align=center border=0>');

document.write('<tr>');
document.write('<td align="center" colspan="2" height="10">');
document.write('</td>');
document.write('</tr>');
document.write('<TR>');

document.write('</TR>');

document.write('</TR>');
document.write('</TABLE>');
document.write('<table cellSpacing=0 cellPadding=0 ><tr><td><IMG height=21 src="images/QuickBar_rateAllCmr.jpg" width=18 /></td></tr></table>');
document.write('<TD width=9 background="images/QuickBar_bgtext_07.png"> </TD>');
document.write('</TR>');
document.write('<TR>');
document.write('<TD><IMG height=9 alt="" src="images/QuickBar_bgtext_08.png" width=9 /></TD>');
document.write('<TD background="images/QuickBar_bgtext_09.png"><IMG height=1 src="spacer.gif" width=1 /></TD>');
document.write('<TD><IMG height=9 alt="" src="images/QuickBar_bgtext_10.png" width=9 /></TD>');
document.write('</TR>');
document.write('</TABLE>');
document.write('</div>');

document.write('</div>');

function at_show_aux(parent, child) {
    var p = document.getElementById(parent);
    var c = document.getElementById(child);

    var top = (c["at_position"] == "y") ? p.offsetHeight + 2 : 0;
    var left = (c["at_position"] == "x") ? p.offsetWidth + 2 : 0;

    for (; p; p = p.offsetParent) {
        top += p.offsetTop;
        left += p.offsetLeft;
    }

    c.style.position = "absolute";
    c.style.top = top + 'px';
    c.style.left = left + 'px';
    if (child == "menu_child6") {
        c.style.left = left - 8;
    }
    if (child == "menu_child7") {
        c.style.top = (top) + 'px';
        c.style.left = (left - 50) + 'px';
        c.style.height = '140px';
    }
    c.style.visibility = "visible";
}

function at_show()
{
  var p = document.getElementById(this["at_parent"]);
  var c = document.getElementById(this["at_child" ]);

  at_show_aux(p.id, c.id);
  clearTimeout(c["at_timeout"]);
}

function at_hide()
{
  var p = document.getElementById(this["at_parent"]);
  var c = document.getElementById(this["at_child" ]);

  c["at_timeout"] = setTimeout("document.getElementById('"+c.id+"').style.visibility = 'hidden'", 1);
}

function at_click()
{
  var p = document.getElementById(this["at_parent"]);
  var c = document.getElementById(this["at_child" ]);

  if (c.style.visibility != "visible") at_show_aux(p.id, c.id); else c.style.visibility = "hidden";
  return false;
}

function at_attach(parent, child, showtype, position, cursor)
{
  var p = document.getElementById(parent);
  var c = document.getElementById(child);

  p["at_parent"]     = p.id;
  c["at_parent"]     = p.id;
  p["at_child"]      = c.id;
  c["at_child"]      = c.id;
  p["at_position"]   = position;
  c["at_position"]   = position;
  p["at_position"]   = position;
  c["at_position"]   = position;
  c.style.position   = "absolute";
  c.style.visibility = "hidden";
  c.style.zIndex = "100";

  if (cursor != undefined) p.style.cursor = cursor;

  switch (showtype)
  {
    case "click":
      p.onclick     = at_click;
      p.onmouseout  = at_hide;
      c.onmouseover = at_show;
      c.onmouseout  = at_hide;
      break;
    case "hover":
      p.onmouseover = at_show;
      p.onmouseout  = at_hide;
      c.onmouseover = at_show;
      c.onmouseout = at_hide;
      break;
  }
}
at_attach("menu_parent0", "menu_child0", "hover", "y", "pointer");
at_attach("menu_parent1", "menu_child1", "hover", "y", "pointer");
at_attach("menu_parent2", "menu_child2", "hover", "y", "pointer");
at_attach("menu_parent3", "menu_child3", "hover", "y", "pointer");
at_attach("menu_parent4", "menu_child4", "hover", "y", "pointer");
at_attach("menu_parent5", "menu_child5", "hover", "y", "pointer");
at_attach("menu_parent6", "menu_child6", "hover", "y", "pointer");
/*at_attach("menu_parent7", "menu_child7", "click", "y", "pointer");*/
at_attach("QuickMenu", "menu_child7", "hover", "y", "pointer");

/* Quick Menu */
document.getElementById('ArrowL').onclick = slideImg;
document.getElementById('QuickMenu').onclick = slideImg;
var obj = document.getElementById('QuickMenu');
var marginLeft = parseInt(obj.style.marginLeft);
var marginLeftNum = parseInt(marginLeft);
var timeOut;
var incres;
var range;
function slideImg() {
    if (marginLeftNum == 0) {
        range = 80;
        incres = 10;
    } else {
        range = 0;
        incres = -10;
    }
    slide();
}
function slide() {
    var IsSilde = true;
    if (marginLeftNum == range) {
        IsSilde = false;
    }
    if (IsSilde) {
        marginLeftNum = marginLeftNum + (incres);
        document.getElementById('QuickMenu').style.marginLeft = marginLeftNum + "px";
        timeOut = setTimeout("slide()", 1);
    } else {
        clearTimeout(timeOut);
    }
}
