/**
 * @author egrissom
 */

$(document).ready(function() {
	
	
	
	if ($.browser.msie && $.browser.version < 7) {
		$("#galleries .overlay img").removeClass("reflected");
	}
	$("#galleries .overlay").css("visibility","visible");
	$("#galleries .overlay").hide();
	
	
	
	$("#gallery a").overlay({
	
		// a position where overlay is placed. this is added to the current scroll position 
		top: 50,
		
		// the time in milliseconds how long the background image grows  
		speed: 500,
		
		
		/* 
	 this callback function is triggered before the growing animation
	 returning false in the callback prevent's it from loading
	 */
		onBeforeLoad: function() { 
			
			this.ifixpng();
			$('div.close').ifixpng();
			this.expose();   
    	}, 
		
		// this callback function is triggered when animation is done and overlay is in place 
		onLoad: function() {
			
		},
		
		/* 
	 this callback function is triggered when overlay is closed
	 returning false in the callback prevent's it from closing
	 */
		onClose: function(content) { 
        	$.unexpose(); 
    	}, 
		
		// clicking outside the overlay close it. by setting this to false doesn't do it 
		closeOnClick: true,
		
		/* 
	 if this is null close button is auto-generated,
	 see below how to make custom buttons.
	 */
		close: null
	
	});
	
	
});

$(window).bind("load", function() { 
		$('img.reflect').reflect({height: 0.1}); 
});

