// JavaScript Document

var gallery = new Array(10);
var maxGallery = 3;
function loadGallery(aNumber) {
	switch(aNumber) {
	  case 2:
		gallery[0] = new Picture("hunter-11.jpg", "");
		gallery[1] = new Picture("hunter-12.jpg", "");
		gallery[2] = new Picture("hunter-13.jpg", "");
 		gallery[3] = new Picture("hunter-14.jpg", "");
		gallery[4] = new Picture("hunter-15.jpg", "");
		gallery[5] = new Picture("hunter-16.jpg", "");
		gallery[6] = new Picture("hunter-17.jpg", "");
		gallery[7] = new Picture("hunter-18.jpg", "");
		gallery[8] = new Picture("hunter-19.jpg", "");
		gallery[9] = new Picture("hunter-20.jpg", "");		
		break;
	  case 3:
	  	gallery[0] = new Picture("hunter-21.jpg", "");
	  	gallery[1] = new Picture("hunter-22.jpg", "");
	  	gallery[2] = new Picture("hunter-23.jpg", "");
	  	gallery[3] = new Picture("hunter-24.jpg", "");
	  	break;
	  default:
	  	gallery[0] = new Picture("hunter-01.jpg", "");
		gallery[1] = new Picture("hunter-02.jpg", "");
		gallery[2] = new Picture("hunter-03.jpg", "");
		gallery[3] = new Picture("hunter-04.jpg", "");
		gallery[4] = new Picture("hunter-05.jpg", "");
		gallery[5] = new Picture("hunter-06.jpg", "");
		gallery[6] = new Picture("hunter-07.jpg", "");
		gallery[7] = new Picture("hunter-08.jpg", "");
		gallery[8] = new Picture("hunter-09.jpg", "");
		gallery[9] = new Picture("hunter-10.jpg", "");
		break;
	}
}

function Picture(aPicture, aDesc) {
	this.picture = aPicture;
	this.desc = aDesc;
}

function getStartingPicText() {
	return "<img src=\"pics/" + gallery[0].picture + "\" name=\"MainImage\"><br>";
}

function getStartingPicDesc() {
	return gallery[0].desc;
}

function getStartingPic() {
	return gallery[0].picture;
}

function getThumbText(aNumber) {
	return "<a href=\"javascript:update('pics/" + gallery[aNumber -1].picture + "', 9);\" onClick=\"document.OrderForm.item_name.value= '" + gallery[aNumber -1].desc + "';\"> <img src=\"thumbnails/" + gallery[aNumber -1].picture + "\" border=\"0\">";

}

function getGalleryTitle() {
	return "Hunter &amp; Jumper"
} 

function getGalleryDescription() {
	return "I grew up riding hunters and have photographed Hunter &amp; Jumper shows in Wisconsin, Illinois, Minnesota, North Carolina, Virginia, Indiana, Missouri, Iowa, Nebraska, Washington D.C. and Michigan. I may have missed some states but you get the idea."
} 