// Title: Beaudesert Hibernian Race Club - javascript
// Author: Kalon Edser, http://www.kalonedser.com/
// Updated: 26 May 2009

jQuery(document).ready(function() {
	
	$('body').addClass('js');
	
	$("a[rel^='prettyPhoto']").prettyPhoto({
			animationSpeed: 'normal', /* fast/slow/normal */
			padding: 40, /* padding for each side of the picture */
			opacity: 0.35, /* Value betwee 0 and 1 */
			showTitle: false, /* true/false */
			allowresize: true, /* true/false */
			counter_separator_label: '/', /* The separator for the gallery counter 1 "of" 2 */
			theme: 'light_square' /* light_rounded / dark_rounded / light_square / dark_square */
		});
	
	// fix png images with alpha channels
	$.ifixpng('../img/pixel.gif');
	$('.png').ifixpng();
	
	$.localScroll({
		hash: true,
		margin: true
	});
	$.localScroll.hash({
		margin: true
	});
	
	$('.event h4:first').addClass('first');
	$('.event .download:last').addClass('last');


	// open new window for external links
	$('A[rel="external"]').click( function() {
        window.open( $(this).attr('href') );
        return false;
    });

});
