<!--
// +------------------------------------------------------J. Eusebio Bolon [SEBI] - 28/03/2007 ---+
// |   REALIZADO EN | HOBERON DESARROLLO E INNOVACION                                             |
// |    DESCRIPCION | JS con las funciones de SlideShow Avanzado.                                 |
// +----------------------------------------------------------------------------------------------+

// +----------------------------------------------------------------------------------------------+
// | Definicio de variables globales                                                              |
// +----------------------------------------------------------------------------------------------+
var Pic = new Array();		// Array que contendra ņa configuracion de las imagenes
var t;						//variable que guarda el valor de la ejecucion
var j = 0;					//Indicador de la posicion del array en la que nos encontramos
var p = 0;					//variable con el tamaņo del array
var preLoad = new Array();	//Array con las imagenes
var preEfec = new Array();	//Array con los efectos de cada imagen
var preDura = new Array();	//Array con ladiracion de cada efecto
var preVisi = new Array();	//Array con el tiempo de visionado de la imagen


// +----------------------------------------------------------------------------------------------+
// | Array con la definicion de las accion                                                        |
// +----------------------------------------------------------------------------------------------+
//  Defino la matriz con imagen, efecto(0-23), Duracions (en segundos del efecto), tiempo visionado imagen
/*20090323
Pic[0] = ["./img/foto01.jpg","0","2","8"];
Pic[1] = ["./img/foto02.jpg","0","2","8"];
Pic[2] = ["./img/foto03.jpg","0","2","8"];
Pic[3] = ["./img/foto04.jpg","0","2","8"];
*/
Pic[0] = ["./img/foto05.jpg","0","2","8"];
Pic[1] = ["./img/foto06.jpg","0","2","8"];
Pic[2] = ["./img/foto07.jpg","0","2","8"];
Pic[3] = ["./img/foto08.jpg","0","2","8"];
Pic[4] = ["./img/foto09.jpg","0","2","8"];
Pic[4] = ["./img/foto10.jpg","0","2","8"];
p = Pic.length;

// +----------------------------------------------------------------------------------------------+
// | No editar a partir de aqui                                                                   |
// +----------------------------------------------------------------------------------------------+
//Descompongo el array inicial en sus correspondientes funcionalidades
for (i = 0; i < p; i++)
{
	preLoad[i] = new Image();
	preLoad[i].src = Pic[i][0];
	preEfec[i] = Pic[i][1];
	preDura[i] = Pic[i][2];// Duration of crossfade (seconds)
	preVisi[i] = (Pic[i][3] * 1000);// Set slideShowSpeed ()
}

function runSlideShow(){
	var j_aux = j;

	//if (document.all){
		if (preEfec[j] != 0)
		{
			//trans show
			//document.images.SlideShow.style.filter="revealTrans(Duration="+ preDura[j] +",Transition="+ preEfec[j] +"))";
			//document.images.SlideShow.filters.revealTrans.Apply();
			//document.images.SlideShow.filters.revealTrans.Play();
			
			document.getElementById("SlideShow").style.filter="revealTrans(Duration="+ preDura[j] +",Transition="+ preEfec[j] +"))";
			document.getElementById("SlideShow").filters.revealTrans.Apply();
			document.getElementById("SlideShow").filters.revealTrans.Play();
			
		}
		else
		{
			//slide show
			//document.images.SlideShow.style.filter="blendTrans(duration="+ preDura[j] +")";
			//document.images.SlideShow.filters.blendTrans.Apply();
      		//document.images.SlideShow.filters.blendTrans.Play();
			
			//detecto el navegador
			if (navigator.appName == "Microsoft Internet Explorer") 
			{
				document.getElementById("SlideShow").style.filter="blendTrans(duration="+ preDura[j] +")";
				document.getElementById("SlideShow").filters.blendTrans.Apply();
	      		document.getElementById("SlideShow").filters.blendTrans.Play();
			}
		}
		document.getElementById("SlideShow").src = preLoad[j].src;
	//}

	j = j + 1;
	if (j > (p-1)) {j=0;}
	t = setTimeout('runSlideShow()', preVisi[j_aux]);
}


/*	
// +----------------------------------------------------------------------------------------------+
// | DEFINICION DE LOS DIFERENTES EFECTOS DISPONIBLES                                             |
// +----------------------------------------------------------------------------------------------+
0  slide show
1  Reveal from inside out 
2  Scroll in from outer parts 
3  Scroll out from center 
4  Scroll up from button 
5  Scroll down from top 
6  Scroll left to right 
7  Scroll right to left 
8  Vertical Blinds left to right 
9  Horizontal Blinds top to bottom 
10  Combination of 8 and 9 
11  Looks a lot like 8 
12  Comes in in pixels 
13  Scroll in from outer parts 
14  Scroll out from center 
15  Close from both top and bottom 
16  Open from center to top and bottom 
17  Diagonal roll from right to left 
18  Different angle diagonal roll right to left 
19  Number 17: the other way 
20  Number 18: the other way 
21  Random horizontal lines 
22  Random vertical lines 
23  Completely Random 
*/
//-->
