// JavaScript Document

/* To use this file, add this line to the html page, in the <head> section,
	before any function scripts.
<script type='text/javascript' src="javascript/jsHeadPictVars.js"></script>
*/

/* The variables in this file are used in displaying the randomly chosen pictures
	in the left-hand border.
	
	Since the deptFolderNames and deptFolderLen arrays determine which folders the
	pictures will be pulled from, they need to be customized for each department 
	page.
	
	This file is therefore NOT included via the page templates. It must be customized though
	(that is, the deptFolderNames and deptFolderLen arrays must be set), and then the file 
	must be added into the page created from the template, e.g. jsHeadPictDept-HistoryVars.js or
	jsHeadPictDept-ArtVars.js 
*/

// These variables are for getting pictures onto the left border.
// First, we define an array of all the folder names in it. This array should be updated
//	when new folders that we want to take pictures from are added. The companion
// array is deptFolderLen, which holds the number of pictures actually in the folder.
//
// Note that, by convention, the folders are in a 'departement' folder in the 'images'
// folder, and each contain two folders - 'small' and 'large'. Files in the 'small'
// folder should be jpg format, ~113 pixels high and 150 pixels wide. The format should
// be landscape, and the 150px width is important since that is width of the blue border
// on the left side of the page.
var deptFolderNames = new Array ("art", "athletics", "english", "grade_6", "history", 
	"math", "media", "music", "other", "phys_ed", "science", "teachers", "tech", "world_lang");
var deptFolderLen = new Array (6, 5, 6, 10, 3, 7, 3, 4, 14, 3, 8, 15, 5, 4);

var numDepts = deptFolderNames.length;

// We also use an array to keep track of which department folders have been used to get a picture, 
// deptArray, and which picture in the folder is next to be displayed, picArray.
var deptArray = new Array();
var picArray = new Array ();

// This variable keeps track of how many times we've tried to get pictures but keep
// getting folders we already used
var numTries = 0;
