﻿// JScript File
var ImagenActual = '';



//CAMBIAMOS EL TAMAÑO DE LETRA DE EL BOTON QUE ESTE ACTIVADO DEL MENU
//Y LE PONEMOS EL NUEVO TAMAÑO A MENU INDICADO Y 
function Ajustafuente()
{
    var uls = document.getElementsByTagName("ul");
    
    for (var uli=0;uli<uls.length;uli++) {
			var ul=uls[uli];
			if (ul.nodeName=="UL") {
					if (!ul.childNodes || ul.childNodes.length==0) { return; }
	                // Iterate LIs
	                
	                
	                for (var itemi=0;itemi<ul.childNodes.length;itemi++) {
		                var item = ul.childNodes[itemi];
		                
		                if (item.nodeName == "LI") {		                    
		                    item.firstChild.style.color="white";
		                    if( item.firstChild.id=='idDoubleSpace' )
		                    {   item.firstChild.style.fontSize='9pt';
		                        continue;
		                    }else if ( item.firstChild.id=='A1' || item.firstChild.id=='A2' || item.firstChild.id=='A3' ){
		                        continue;
		                    }		                    
		                    item.firstChild.style.fontSize='10pt';		                    
		                }
		            }

			}
		}
}



//function CargarAtraction(Atraccion)
//{

//    var tblRental = document.getElementById('tblRentalId');
//    var tblAtractions = document.getElementById('idtblAtractions');
//    //Ocultamos los textos 
//    document.getElementById('lblTitleAtraction').style.display = 'none';
//    document.getElementById('lblDescriptionAtraction').style.display = 'none';
//    tblAtractions.style.backgroundImage='';
//    tblRental.style.backgroundImage=''; 
//    
//  
//    //Limpiamos las imagenes
//    tblRental.style.backgroundImage = '';
//    tblAtractions.style.backgroundImage='';
//    
//    if ( Atraccion == 'Rental' )
//    {
//        //Validamos que idioma es Ingles o Español
//        if ( this.Mensajes.lblAboutUs == 'About us' )    //En caso de que sea Ingles
//        {   tblRental.style.backgroundImage='url(../../Images/RentalUS.png)'; 
//        } else {
//            tblRental.style.backgroundImage='url(../../Images/RentalMX.png)'; 
//        }
//        tblRental.style.backgroundRepeat= 'no-repeat';
//        return;
//    }else{        
//        var Idioma = '';    
//        if ( this.Mensajes.lblAboutUs == 'About us' )    //En caso de que sea Ingles
//        {   Idioma = ''
//        } else {
//            Idioma = 'MX'
//        }    
//        tblAtractions.style.backgroundImage='url(../../Images/' + Atraccion + Idioma + '.png)';
//        tblAtractions.style.backgroundRepeat= 'no-repeat';        
//    }
//    
//    ActualizarIdiomas(Atraccion);
//}



//function ActualizarIdiomas(Atraccion)
//{
//    var desc = document.getElementById('lblDescriptionAtraction');
//    var title = document.getElementById('lblTitleAtraction');
//    desc.style.display = 'inline'
//    title.style.display = 'inline'
//    
//    switch (Atraccion)
//    {
//        case 'AboutUs':
//            desc.innerText = this.Mensajes.lblDescAboutUs;
//            title.innerText = this.Mensajes.lblAboutUs;
//            break;

//        case 'WavePool':
//            desc.innerText = this.Mensajes.lblDescWavePool;
//            title.innerText = this.Mensajes.lblWavePool;
//            break;
//            
//        case 'KidsPark':
//            desc.innerText = this.Mensajes.lblDescKidsPark;
//            title.innerText = this.Mensajes.lblKidsPark;
//            break;
//        
//        case 'Twister':
//            desc.innerText = this.Mensajes.lblDescTwister;
//            title.innerText = this.Mensajes.lblTwister;
//            break;
//        
//        case 'BumperBoat':
//            desc.innerText = this.Mensajes.lblDescBumperBoat;
//            title.innerText = this.Mensajes.lblBumperBoat;
//            break;
//        
//        case 'DoubleSpace':
//            desc.innerText = this.Mensajes.lblDescDoubleSpace;
//            title.innerText = this.Mensajes.lblDoubleSpace;
//            break;
//        
//        case 'Kamikaze':
//            desc.innerText = this.Mensajes.lblDescKamikaze;
//            title.innerText = this.Mensajes.lblKamikaze;
//            break;
//        
//        case 'BubbaTub':
//            desc.innerText = this.Mensajes.lblDescBubbaTub;
//            title.innerText = this.Mensajes.lblBubbaTub;
//            break;
//        
//        case 'LazyRiver':
//            desc.innerText = this.Mensajes.lblDescLazyRiver;
//            title.innerText = this.Mensajes.lblLazyRiver;
//            break;
//       
//        default:
//            break;
//    }  

//}



//function PonerFondo()
//{
//    tblAtractions.style.backgroundColor='Transparent';
//    tblAtractions.style.filter='';
//}


//function Limpiafondo()
//{
//    document.getElementById('lblTitleAtraction').style.display = 'none';
//    document.getElementById('lblDescriptionAtraction').style.display = 'none';
//    tblAtractions.style.backgroundImage='';
//    tblRental.style.backgroundImage=''; 
//}


//function PoneImagen()
//{
//    document.getElementById('Image1').style.backgroundImage='url(../../Images/Kamikaze.png)';
//}

function PoneImagen(Atraccion)
{
    //var AnimacionBoton = $get("idWavePool");
    ImagenActual = Atraccion;
    
    var Imagen = document.getElementById('Image1');
    
//    if ( Atraccion == 'Rental' )
//    {
//        //Validamos que idioma es Ingles o Español
//        if ( this.Mensajes.lblAboutUs == 'About us' )    //En caso de que sea Ingles
//        {   Imagen.style.backgroundImage='url(../../Images/RentalUs.png';
//        } else {
//            Imagen.style.backgroundImage='url(../../Images/RentalUs.png';RentalMX.png)'; 
//        }
//        tblRental.style.backgroundRepeat= 'no-repeat';
//        return;
//    }else{        

        //En caso de que la atraccion sea 
        Imagen.style.backgroundImage='';
        
        var Idioma = '';    
        if ( this.Mensajes.lblAboutUs == 'About us' )    //En caso de que sea Ingles
        {   Idioma = ''
        } else {
            Idioma = 'MX'
        }
        Imagen.style.backgroundImage='url(../../Images/' + Atraccion + Idioma + '.png)';
        Imagen.style.backgroundRepeat= 'no-repeat';

//    }
    
//    var onclick = $find("idWavePool").get_OnClickBehavior().get_animation();   
//    onclick.set_target("Image1");
//    onclick.play();
    
    //$find('idWavePool').get_OnClickBehavior().get_animation().play();
    
    //$find('BOpenAnimation').OnClick();
//    AjaxControlToolkit.Animation.Animation.play("idWavePool");
    
}


function abrir()
{    
    if ( this.Mensajes.lblAboutUs == 'About us' )    //En caso de que sea Ingles
    {   Idioma = '';
        window.location = "../Formularios/PrivacyUS.aspx";    
        //window.open('../Formularios/PrivacyUS.aspx',"WetnWild.com | Términos y Condiciones | Español",'toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=yes,resizable=no,width=1024,height=768');
    } else {
        Idioma = 'MX';
        window.location = "../Formularios/PrivacyMX.aspx";
        //window.open('../Formularios/PrivacyMX.aspx',"WetnWild.com | Términos y Condiciones | Español",'toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=yes,resizable=no,width=1024,height=768');
    }  
}



function abrirWet()
{
    window.open('../Formularios/Home.aspx',"Wetn Wild",'toolbar=yes,location=yes,directories=yes,status=yes,menubar=yes,scrollbars=yes,resizable=yes,width=1024,height=768');
}