/*------------------------------------------------------------------------------------------------*/
/*                                                                                                */
/*  Javascript gamesdeclic with scriptaculous and dojo's lib - contact sir_bline@hotmail.com      */
/*  find most of source for the lib by scriptaculous or dojo's lib                                */
/*  gamesdeclic js is freely distributable under the terms of the gnu licence                     */
/*  Prototype is freely distributable under the terms of an MIT-style license.                    */
/*  http://script.aculo.us/ <== for lib                                                           */
/*                                                                                                */
/*------------------------------------------------------------------------------------------------*/

function $() {
  var elements = new Array();

  for (var i = 0; i < arguments.length; i++) {
    var element = arguments[i];
    if (typeof element == 'string')
      element = document.getElementById(element);

    if (arguments.length == 1)
      return element;

    elements.push(element);
  }

  return elements;
}

function navType() {

 var uA= navigator.userAgent;
 var browserType = "unknown";

  if (uA.indexOf("Opera") > -1) {
    browserType = "Opera";
  } else if (uA.indexOf("Safari") > -1) {
    browserType = "Safari";
  } else if (uA.indexOf("Konqueror") > -1) {
    browserType = "Konqueror";
  } else if (uA.indexOf("Gecko") > -1) {
    browserType = "Mozzilla";
  } else if (uA.indexOf("MSIE") > -1) {
    browserType = "Internet Explorer";
  }

}


var btnNxt = '1';

function Sui(val,minVal,maxVal,Id) {

  if(val == '1') { 

    if(btnNxt < maxVal) {

      var current = btnNxt;
      btnNxt++; itere(Id,current,btnNxt);

      return false;

    } else { return false; }

  } else if(val == '0') { 

    if(btnNxt > minVal) {

      var current = btnNxt;
      btnNxt--; itere(Id,current,btnNxt);

      return false;

    } else { return false; }

  }

  function itere(Id,current,btn) {

    $(Id + current).style.display = "none";
    $(Id + btn).style.display = "block";
    $(page).innerHTML = btn;

  }

}



function smpMen(layer,layName) {
  if (layer == '1') {
    $(layName).style.visibility = "visible";
    return false;
  } else  {
    $(layName).style.visibility = "hidden";
    return false;
  }
}



function showHeurre() {

  var d = new Date();
  var minutes = d.getMinutes();
  var secondes = d.getSeconds();

  if(d.getMinutes() < 10) { var minutes = "0" + d.getMinutes(); }
  if(d.getSeconds() < 10) { var secondes = "0" + d.getSeconds(); }
  $("hol").innerHTML = d.getHours() + ":" + minutes + ":" + secondes + " Gmt";
  setTimeout("showHeurre()",1000); return false;

}


function globals() {

document.onselectstart = new Function ("return false");
document.oncontextmenu = new Function ("return false");

}
