// Various navigation and list based styles. Mostly removing the borders
jQuery(function($) {
	$('.gallery').css('visibility', 'visible');

    $('.header ul').each(function () {
        $(this).find('li').last().addClass('last');
        $(this).find('li').first().addClass('first');
    });
    $('.footer li').last().addClass('last');

    $(".header ul li").hover(function () {

        if ($(this).children('ul').size() > 0) {
            $(this).addClass("hover");
            $('ul:first', this).css('visibility', 'visible');
        } else {
            return false;
        }

    }, function () {

        $(this).removeClass("hover");
        $('ul:first', this).css('visibility', 'hidden');

    });

    $(".header ul li ul li:has(ul)").find("a:first").append(" &raquo; ");
    var wrapper = $('.wrapper');
    var dh = $(window).height();
    
    if(wrapper.height() < dh) {
		wrapper.height(dh);
    }

    
    $('.snail, .snail *').mousedown(function() {
		
		window.location = '/contact-maps/contact-us-2/';
		$(this).blur();
		return false;
    
    });
    
    $('.home-flash-left, .home-flash-left *').mousedown(function() {
		
		window.location = '/long-lake/photo-reel/';
		$(this).blur();
		return false;
    
    });  
    
    
        
});
jQuery(document).ready(function($){	
	$("#slider").easySlider({
		auto: true,
		continuous: true,
		controlsShow: false,
		speed: 800,
		pause: 4000 
	});
	$("#slider3").easySlider({
		auto: true,
		continuous: true,
		controlsShow: false,
		speed: 800,
		pause: 5000 
	});
});

// Dynamic Flash Heading text replacement
var avenir = {
    src: '/wp-content/themes/longlake/scripts/dearjoeitalic.swf'
};

sIFR.activate(avenir);

sIFR.replace(avenir, {
    selector: '.post h2, .post h1, .title',
    wmode: 'transparent',
    css: ['.sIFR-root {color:#330000;}']
});


// Load the SWF file for Snail Mail
swfobject.registerObject("SnailMail", "9.0.0", "expressInstall.swf");

