/**************************************************************************
 * ToHex
 * Convert a int into a hex string
 * 
 **************************************************************************/
  function MakeArray(n)
	{
    this.length=n;
    for(var i=1; i<=n; i++) this[i]=i-1;
    return this
  }

  hex=new MakeArray(16);
  hex[11]="A"; hex[12]="B"; hex[13]="C"; hex[14]="D";
  hex[15]="E"; hex[16]="F";

  function ToHex(x){  // Changes a int to hex (in the range 0 to 255)
    var high=x/16;
    var s=high+"";        //1
    s=s.substring(0,2);   //2 the combination of these = trunc funct.
    high=parseInt(s,10);  //3
    var left=hex[high+1]; // left part of the hex-value
    var low=x-high*16;    // calculate the rest of the values
    s=low+"";             //1
    s=s.substring(0,2);   //2 the combination of these = trunc funct.
    low=parseInt(s,10);   //3
    var right=hex[low+1]; // right part of the hex-value
    var string=left+""+right; // add the high and low together
    return string;
  }
/**************************************************************************/

/**************************************************************************
 * lum( color, 
 * 
 * 
 **************************************************************************/


/**************************************************************************
 * loadWhiteFade 
 * 
 * 
 **************************************************************************/
function loadWhiteFade( aRunReload )
{
	window.parent.frames["subguttertop"].location = "fade-brn-wht-1x20.shtml";
	window.parent.frames["subgutterleft"].location = "fade-brn-wht-20x1.shtml";
	// Reload all the Menus so NO buttons are down
	if( aRunReload )
		reloadMenu( -1 );
}

function loadBeigeFade( aRunReload )
{
			window.parent.frames["subguttertop"].location = "fade-brn-beige-128x20.shtml";
			window.parent.frames["subgutterleft"].location = "fade-brn-beige-20x128.shtml";
	// Reload all the Menus so NO buttons are down
	if( aRunReload )
		reloadMenu( -1 );
}


/**************************************************************************
 * loadWhiteFade 
 * 
 * 
 **************************************************************************/
