
/* ---------------------
title: paladone site specific Jquery
author: Chris Bayles
created: 07/10/11
version: 1.0
--------------------- */


/* initiates feature panel cycle */
/* requires jquery.cycle.js */

$(document).ready(function() {
    var $featurePanel = null;
    var $navigationArrows = null;
    $featurePanel = $('.frontpanels');
    $navigationArrows = $('frontpanels a.fade');
    if ($featurePanel.length) {
        $featurePanel.css("overflow", "hidden");
       
        $("ul.panels").cycle({
            fx: 'scrollHorz',
            pause: 1,
            prev: '#prev',
            speed:  '1000',
            timeout:  6000,
            next: '#next'
        });
       
        $featurePanel.hover(function() {
            $navigationArrows.animate({ 'opacity': 1 });
          },
              function() {
            $navigationArrows.animate({ 'opacity': 0.5 });
          });
    }
    $navigationArrows.animate({ 'opacity': 0.5 });
});


/* --------------------- applies classes so that it works on legacy browsers --------------------- */
			
$(document).ready(function(){
  		$('#nav li:first-child').addClass('first');  		
		});
	
   
    
/* --------------------- fades items --------------------- */

$(document).ready(function(){
	
	$("#arrow a").fadeTo("fast", 0.5); // This sets the opacity of the thumbs to fade down to 40% when the page loads

	$("#arrow a").hover(function(){
	
	$(this).fadeTo("fast", 1); // This should set the opacity to 100% on hover
	},function(){
	$(this).fadeTo("fast", 0.5); // This should set the opacity back to 40% on mouseout
	
	});
	
});


/* --------------------- fades content on nav hover --------------------- */

$(document).ready(function(){
    $("#nav").hover(
    function () {
	    $("div#content,div#footer").animate({ 'opacity': 0.3 });
		},
		function () {
        $("div#content,div#footer").animate({ 'opacity': 1 });
      }
    );
});


/* --------------------- fires up scroll pane --------------------- */

$(document).ready(function()
			{
				$('#content').jScrollPane(
					{
						showArrows: true,
						arrowScrollOnHover: true
					}
				);
			});

