
function select_game(game_id) {
  location.href='serverlist.php?game_id=' + game_id;
}

function extra_stylesheet() {
}

function selectGame(game_id) {
  if(game_id != '') {
    if( document.all ) {
      tMenu = document.all("treeMenu" + game_id).style;
      tIcon = document.all("treeIcon" + game_id).style;
    } else if( document.getElementById ) {
      tMenu = document.getElementById("treeMenu" + game_id).style;
      tIcon = document.getElementById("treeIcon" + game_id).style;
    }
    if(tMenu.display == 'none') {
      tMenu.display = "block";
      tIcon.backgroundImage = 'url(./img/rmtnavi/game_minus.gif)';  
    } else {
      tMenu.display = "none";
      tIcon.backgroundImage = 'url(./img/rmtnavi/game_plus.gif)';  
    }
  }
}

function nowOnConfig() {
  alert("現在準備中です。今しばらくお待ちください。");
}

function goLink(url) {
  location.href = url;
}

function openLink(url,win,features) {
  newwin = window.open(url,win,features);
  newwin.focus();
}

function scrollGame(game_id) {
  if(game_id != '') {
    if( document.all ){
      target = document.all('treeIcon' + game_id);
      if(target == null) {
        return ;
      }
      scrollArea = document.all('left_gamelist_field');
      scrollArea.scrollTop = target.offsetTop;
    } else if( document.getElementById ){
      target = document.getElementById('treeIcon' + game_id);
      if(target == null) {
        return ;
      }
      scrollArea = document.getElementById('left_gamelist_field');
      scrollArea.scrollTop = target.offsetTop - 358;
    }
  }
}

function getCSS() {
  if(navigator.userAgent.indexOf("Mozilla/5.") >= 0) {
    if(navigator.userAgent.indexOf("Chrome") >= 0) {
      document.write('<link href="css/base_chrome.css" rel="stylesheet" type="text/css" />');
    } else {
      document.write('<link href="css/base_mozilla.css" rel="stylesheet" type="text/css" />');
    }
  } else {
    var uName = navigator.userAgent;
    sPtr = uName.indexOf("MSIE");
    ePtr = uName.indexOf(";",sPtr);
    ver = eval(uName.substring(sPtr+5,ePtr));
    if(ver == 6) {
      document.write('<link href="css/base_ie6.css" rel="stylesheet" type="text/css" />');
    } else {
      document.write('<link href="css/base.css" rel="stylesheet" type="text/css" />');
    }
  }
}

function clickRewind(wzprice,noprice) {
  if(document.all("rewindcheckbox").checked == true) {
    document.all("totalprice").innerHTML = wzprice;
  } else {
    document.all("totalprice").innerHTML = noprice;
  }
}

