$(document).ready(function () {

//////////////////////////////////////////////////////////////////////////////////
// Activate image cycle on home page
//////////////////////////////////////////////////////////////////////////////////
$("#main_image").cycle();
//////////////////////////////////////////////////////////////////////////////////
// Animate opacity of album choice buttons
//////////////////////////////////////////////////////////////////////////////////
$('#album_choice img, #publication_choice img').animate({ opacity: 0.6 }, 300);						   
$('#album_choice img, #publication_choice img').each(function() {
            $(this).hover(function() {
                $(this).stop().animate({ opacity: 1.0 }, 300);
            },
           function() {
               $(this).stop().animate({ opacity: 0.6 }, 600);
           });
});
//////////////////////////////////////////////////////////////////////////////////
// Animate opacity of language choice buttons
//////////////////////////////////////////////////////////////////////////////////
$('#lang_choice a.inactive_lang').hover(function() {
	$(this).stop().animate({opacity:1}, 100);									 
						 }, function () {
	$(this).stop().animate({opacity:.5}, 300);
});
//////////////////////////////////////////////////////////////////////////////////
// Add focus class to textareas & inpouts on focus
//////////////////////////////////////////////////////////////////////////////////
$('input').live('focusin', function() {
	$(this).addClass("focus");			  
});
	
$('input').live('focusout',function() {
	$(this).removeClass("focus");			  
});

$('textarea').live('focusin',function() {
	$(this).addClass("focus");			  					  
});
	
$('textarea').live('focusout',function() {
	$(this).removeClass("focus");			  
});


//////////////////////////////////////////////////////////////////////////////////
// Add stripping to tables
//////////////////////////////////////////////////////////////////////////////////
zebraRows('table tbody tr:odd td', 'odd');



$("a#active").click(function() { return false; });

//$('#publication_thumbnails').jScrollPane();

//$('#publication_thumbnails').localScroll();
$('.email').defuscate();
//////////////////////////////////////////////////////////////////////////////////
});//end doc ready
$(document).bind("contextmenu",function(e){
        return false;
});//disactivate right click
DD_belatedPNG.fix('.png_fix');// fix png transparency IE6 

//table striping
function zebraRows(selector, className)
{
  $(selector).removeClass(className).addClass(className);
}
    
