//---------------------------------------------------------------------------------------------
// --------- ---- ---- --- --- ---     sound handler       ---- ------- ---- ---- --- --- -----
//---------------------------------------------------------------------------------------------
function GetInfo() {

this.fromflash;
this.var2;

}

// for taccess through index page
function Begin(){
		WholeScreen();
		sound('../sound-on.html');
}


function FindFormer(){

	var pathArray = window.location.href.split( '=' );
	menu.fromflash = parseInt(pathArray[1]);
}

// for direct access to the pages
function Begin2(){
	
	menu =new GetInfo();
	FindFormer();
	WholeScreen();
 	CheckOpenDirect();
		
}



function CheckOpenDirect(){
	
	if(menu.fromflash!=1){
		sound('../sound-on.html');
	}
}

//this function will be called by "off" button inside index.fla
function CheckOpen(){sound('../sound-on.html');	
}


function CheckOpenoff(){sound('../sound-off.html');
}



// -----------------------------------------  
// -----   comon fucntions to both pages 
// -----------------------------------------  
function WholeScreen(){
	
	self.moveTo(0,0);
    self.resizeTo(screen.availWidth,screen.availHeight);
}

function nueva(where){
   var nueva = window.open(where,"nueva",'fullscreen=no,toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0,width=370,height=380');
   nueva.moveTo(0,0);nueva.focus();
 }


function sound(soundstatus) {
	
   var my_window = window.open(soundstatus,"my_window","menubar=0,location=0,directories=0,toolbar=0,status=0,scrollbars=0,resizable=1,width=300,height=300");
   self.focus();
  //my_window.document.isopen=1;
}



