/* Blink */
$(document).ready(function() {
		// If browser is Internet Explorer
		if ($.browser.msie) {
			
			$('body').addClass('no-animations');
			$('.gallery .photo a').hover(function() {
				$(this).find('.hover_bg_circle').show();
			},function() {
				$(this).find('.hover_bg_circle').hide();
			});
		
		// If browser isn't Internet Explorer
		} else {
			$('body').addClass('cssanimations');
			$('.gallery .photo a').hover(function() {
				$(this).find('.hover_bg_circle').stop().animate({top: '40px'}, 400);
				$(this).find('img').fadeTo(400, 0.7);
			},function() {
				$(this).find('.hover_bg_circle').stop().animate({top: '200px'}, 400);
				$(this).find('img').fadeTo(400, 1);
			});
		}
	});

(function($) {
	$.fn.blink = function(options) {
		var defaults = { delay:500 };
		var options = $.extend(defaults, options);
		
		return this.each(function() {
			var obj = $(this);
			setInterval(function() {
				if ($(obj).css("visibility") == "visible") {
					$(obj).css('visibility','hidden');
				} else {
					$(obj).css('visibility','visible');
				}
			}, options.delay);
		});
	}
}(jQuery))

