// Set slideShowSpeed (milliseconds)
var slideShowSpeed = 10000;
// Duration of crossfade (seconds)
var crossFadeDuration = 3;
var preLoad = new Array();
var t;
var j;
var p;

function loadHomePic() {

	var HomePic = new Array();
	
	HomePic[0] = 'images/home/1.gif';
	HomePic[1] = 'images/home/2.gif';
	HomePic[2] = 'images/home/3.gif';
	HomePic[3] = 'images/home/4.gif';

	// do not edit anything below this line
	
	j = 0;
	p = HomePic.length;
	
	
	for (i = 0; i < p; i++) {
		preLoad[i] = new Image();
		preLoad[i].src = HomePic[i];
	}
}


function loadLegislationPic() {

	var LegislationPic = new Array();
	
	LegislationPic[0] = 'images/legislation/1.gif';
	LegislationPic[1] = 'images/legislation/2.gif';
	LegislationPic[2] = 'images/legislation/3.gif';
	LegislationPic[3] = 'images/legislation/4.gif';

	// do not edit anything below this line
	
	j = 0;
	p = LegislationPic.length;
	
	
	for (i = 0; i < p; i++) {
		preLoad[i] = new Image();
		preLoad[i].src = LegislationPic[i];
	}
}

function loadGovernmentPolicyPic() {

	var GovernmentPolicyPic = new Array();
	
	GovernmentPolicyPic[0] = 'images/governmentpolicy/1.gif';
	GovernmentPolicyPic[1] = 'images/governmentpolicy/2.gif';
	GovernmentPolicyPic[2] = 'images/governmentpolicy/3.gif';
	GovernmentPolicyPic[3] = 'images/governmentpolicy/4.gif';
	
	// do not edit anything below this line
	j = 0;
	p = GovernmentPolicyPic.length;
	
	for (i = 0; i < p; i++) {
		preLoad[i] = new Image();
		preLoad[i].src = GovernmentPolicyPic[i];
	}

}

function loadEAPolicyPic() {

	var EAPolicyPic = new Array();

	EAPolicyPic[0] = 'images/eapolicy/1.gif';
	EAPolicyPic[1] = 'images/eapolicy/2.gif';
	EAPolicyPic[2] = 'images/eapolicy/3.gif';
	EAPolicyPic[3] = 'images/eapolicy/4.gif';
	
	// do not edit anything below this line
	j = 0;
	p = EAPolicyPic.length;
	
	for (i = 0; i < p; i++) {
		preLoad[i] = new Image();
		preLoad[i].src = EAPolicyPic[i];
	}
		
}

function loadManagementProcessPic() {
	
	var ManagementProcessPic = new Array();

	ManagementProcessPic[0] = 'images/managementprocess/1.gif';
	ManagementProcessPic[1] = 'images/managementprocess/2.gif';
	ManagementProcessPic[2] = 'images/managementprocess/3.gif';
	ManagementProcessPic[3] = 'images/managementprocess/4.gif';
	
	// do not edit anything below this line
	j = 0;
	p = ManagementProcessPic.length;

	for (i = 0; i < p; i++) {
		preLoad[i] = new Image();
		preLoad[i].src = ManagementProcessPic[i];
	}
}

function loadReferencesPic() {
	
	var ReferencesPic = new Array();

	ReferencesPic[0] = 'images/references/1.jpg';
	ReferencesPic[1] = 'images/references/2.jpg';
	ReferencesPic[2] = 'images/references/3.jpg';
	ReferencesPic[3] = 'images/references/4.JPG';
	
	// do not edit anything below this line
	j = 0;
	p = ReferencesPic.length;

	for (i = 0; i < p; i++) {
		preLoad[i] = new Image();
		preLoad[i].src = ReferencesPic[i];
	}

}

function runSlideShow() {
	if (document.all) {
		document.images.SlideShow.style.filter="blendTrans(duration=2)";
		document.images.SlideShow.style.filter="blendTrans(duration=crossFadeDuration)";
		document.images.SlideShow.filters.blendTrans.Apply();
	}
	document.images.SlideShow.src = preLoad[j].src;
	if (document.all) {
		document.images.SlideShow.filters.blendTrans.Play();
	}
	
	j = j + 1;
	if (j > (p - 1)) j = 0;
	t = setTimeout('runSlideShow()', slideShowSpeed);
}