﻿// JScript File
<!--
var temp,imageSource1,imageSource2,imageSource3,imageSource4,imgSource5,imgRollSource1,imgRollSource2,imgRollSource3,imgRollSource4,imgRollSource5
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}

function hideAllBookExtract()
{
  document.getElementById("divBookExtract1").style.visibility="hidden"
  document.getElementById("divBookExtract1").style.position="absolute"
  document.getElementById("divBookExtract2").style.visibility="hidden"
  document.getElementById("divBookExtract2").style.position="absolute"
  document.getElementById("divBookExtract3").style.visibility="hidden"
  document.getElementById("divBookExtract3").style.position="absolute"
  if((imageSource4.length)>1)
  {
  document.getElementById("divBookExtract4").style.visibility="hidden"
  document.getElementById("divBookExtract4").style.position="absolute"
  }
  if((imageSource5.length)>1)
  {
  document.getElementById("divBookExtract5").style.visibility="hidden"
  document.getElementById("divBookExtract5").style.position="absolute"
  }
  if((imageSource6.length)>1)
  {
  document.getElementById("divBookExtract6").style.visibility="hidden"
  document.getElementById("divBookExtract6").style.position="absolute"
  }
}

function showAllImage()
{
  document.getElementById("ImageExtract1").src=imageSource1;
  document.getElementById("ImageExtract2").src=imageSource2;
  document.getElementById("ImageExtract3").src=imageSource3;
  if(imageSource4.length>1)
  {document.getElementById("ImageExtract4").src=imageSource4;}
  else{}
  if(imageSource5.length>1)
  {document.getElementById("ImageExtract5").src=imageSource5;}
  else{}
  if(imageSource6.length>1)
  {document.getElementById("ImageExtract6").src=imageSource6;}
  else{}
}

function initialBookExtract()
{
  hideAllBookExtract();
  document.getElementById("divBookExtract1").style.visibility="visible";
  showAllImage();
  document.getElementById("ImageExtract1").src=imgRollSource1;
  temp="ImageExtract1";
  document.getElementById("ImageExtract1").style.cursor="pointer";
}

function showBookExtract(string1,string2)
{
  if(string1==temp)
  {
	  initialize(string1);
  }
  else
  {
    temp=string1;
    switch(string1){
    case "ImageExtract1":showAllImage();
  						 document.getElementById("ImageExtract1").src=imgRollSource1;
						 document.getElementById("ImageExtract1").style.cursor="pointer";
						 //setTimeout('initialize("ImageExtract1")',1000);
						 break;
						 
    case "ImageExtract2":showAllImage();
  						 document.getElementById("ImageExtract2").src=imgRollSource2;
  						 document.getElementById("ImageExtract2").style.cursor="pointer";
						// setTimeout('initialize("ImageExtract2")',1000);
						 break;
						 						 
    case "ImageExtract3":showAllImage();
  						 document.getElementById("ImageExtract3").src=imgRollSource3;
  						 document.getElementById("ImageExtract3").style.cursor="pointer";
  						 //setTimeout('initialize("ImageExtract3")',1000);
						 break;
						 
    case "ImageExtract4":showAllImage();
  						 document.getElementById("ImageExtract4").src=imgRollSource4;
  						 document.getElementById("ImageExtract4").style.cursor="pointer";
						 //setTimeout('initialize("ImageExtract4")',1000);
						 break;
						 
    case "ImageExtract5":showAllImage();
  						 document.getElementById("ImageExtract5").src=imgRollSource5;
						 document.getElementById("ImageExtract5").style.cursor="pointer";
						 //setTimeout('initialize("ImageExtract5")',1000);
						 break;
	case "ImageExtract6":showAllImage();
  						 document.getElementById("ImageExtract6").src=imgRollSource6;
						 document.getElementById("ImageExtract6").style.cursor="pointer";
						 //setTimeout('initialize("ImageExtract5")',1000);
						 break;
	
	}
  }
  hideAllBookExtract();
  document.getElementById(string2).style.visibility="visible";
 
}

function allImages(Source1,Source2,Source3,Source4,Source5,Source6,RollSource1,RollSource2,RollSource3,RollSource4,RollSource5,RollSource6)
{
  
  imageSource1=Source1;
  imageSource2=Source2;
  imageSource3=Source3;
 
  if(Source4.length>1)
  {imageSource4=Source4;}
  else
  {imageSource4="";}
  if(Source5.length>1)
  {imageSource5=Source5;}
  else
  {imageSource5="";}
  
  if(Source6.length>1)
  {imageSource6=Source6;}
  else
  {imageSource6="";}
	
  imgRollSource1=RollSource1;
  imgRollSource2=RollSource2;
  imgRollSource3=RollSource3;
  if(RollSource4.length>1)
  {imgRollSource4=RollSource4;}
  else
  {imgRollSource4="";}
  if(RollSource5.length>1)
  {imgRollSource5=RollSource5;}
  else
  {imgRollSource5="";}
  
  if(RollSource6.length>1)
  {imgRollSource6=RollSource6;}
  else
  {imgRollSource6="";}
}

function initialize(normal)
{
	document.getElementById(normal).style.cursor="default";
}

//-->

