jQuery(function($) {
	// $('.flash').delay(10000).animate({ height: 0, paddingTop: 0, paddingBottom: 0 });
	$('a.you').click(function(){ return false; });
	$('.user').hover(function(){ $(this).toggleClass("hover") })
	$('.user .actions a[data-remote]')
		.bind("ajax:success", function(event, data, status, xhr) {
			// console.log("success", 	$(this).parents('.action'));
			var active = $(this).parents('.actions').find(".active[data-remote]").first();
			if( active[0] != $(this)[0] ) {
				$(this).parents('.actions').find("a[data-remote]").toggleClass("active");
			}
		})
		.bind("ajax:failure", function() {
			console.log("failure");
		 	alert('Ajax error, try later. Sorry !')
		});
});
