/*SlideShow version 1.6
* by Scott Anderson
* climbers@weekendclimber.com
*
* This program fall under the jurisdiction
* of the GNU General Public Liscense, so
* basically USE IT AT YOUR OWN RISK. If you
* do decide to use it, please let us know.
* We all like to see our babies at work. -Scotty
* 
* If your having problems setting up this script
* check out our new tutorial page at:
* http://www.weekendclimber.com/tutorials/
*/
//Edit these variables
var thumbs = 21; //Number of thumbnail pics
var pic_dir = "images/"; //Directory of the full pics
var pic_ext = ".jpg"; //Extension of the full pics
var place_hold = "images/garden4.jpg"; //Place holder image (save in thumbnail directory `thumb_dir')
var thumb_dir = "images/"; //Directory of thumbnail pics
var thumb_ext = "_th.jpg"; //Etension of the thumbnail pics

//Don't edit below this unless
//you know what's up!
var thumb_img = new Array();
var full_imgtxt = new Array();
function Load_All() {
	for ( i = 0; i < imgs.length; i++ ) {
		thumb_img[ i ] = new Image();
		thumb_img[ i ].src = thumb_dir + imgs[ i ] + thumb_ext;
		full_imgtxt[ i ] = pic_dir + imgs[ i ] + pic_ext;}}
var pos = 0;
function Scroll_Thumb ( way ) {
	if ( way == "next" ) pos += thumbs;
	if ( pos >= imgs.length ) pos -= thumbs;
	if ( way == "prev" ) pos -= thumbs;
	if ( pos < 0 ) pos = 0;
	for ( i = 0; i < thumbs; i++ ) {
		var x = "thumb" + i;
		var y = pos + i;
		if ( thumb_img[ y ] != null ) {
			document.getElementById( x ).src = thumb_img[ y ].src;
		} else {
			document.getElementById( x ).src = thumb_dir + place_hold;}}}
function GotoFrame( num ) {
	if ( num + pos < imgs.length ) {
		document.getElementById( "picture" ).src = full_imgtxt[ num + pos ];}}
