﻿/// <reference path="jquery/jquery-vsdoc.js"/>
/*
	This handles the picture gallery
*/
$(document).ready(function() {
	
	$('#thumbs').height('500px').width('80px').css('float','left');
	$('#thumbs li img').height('75px').width('auto');

	$('#thumbs').jcarousel({
		scroll: 6,
		vertical: true
	});
	/*
		The actual image src is a place holder. The path to the image is
		held in the title attribute. This will cause the images to be loaded
		sequentially after document ready so the user will see them pop into
		view one at a time rather than waiting for all of the images to load
		before seeing anything.
	*/
	$('#thumbs li img').each(function() {
		this.src = this.title;
		this.title = '';
	});

	$('ul#thumbs').galleria({
		history: false,			// activates the history object for bookmarking, back-button etc.
		clickNext: false,			// helper for making the image clickable. 
		insert: '#fullSize',		// the containing selector for our main image. 
		onImage: function() {	// shows the nav when the image is showing
			$('.nav').css('display','block'); 
		} 
	});
});