/*
	Shore Consulting Group
	Creative site
	Javascript
	Nov, 09
*/


$(document).ready(function(){
		//
		// Scroll area
		//$("#entries").scrollable({size:1, horizontal:false}); 
		//
		$("#viewport").css("height","470px");
		$("#entries a.pageTop").remove();
		//
		if(!$.browser.msie){
			$("a.scrollNav").click(function(e){
				e.preventDefault();
				$("#entries").animate({top:-$($(this).attr("href")).position().top},1000,'easeOutExpo');
				//
				moveTo = $(this).attr("rel");
				$("#titleBar h2").fadeOut(400,fadeChange).fadeIn(700)
				//
				$(".scrollNav").removeClass("active");
				$(this).addClass("active");
			});
		} else {
			$("a.scrollNav").click(function(e){
				e.preventDefault();
				$("#entries").animate({top:-$($(this).attr("href")).position().top},1000,'easeOutExpo');
				//
				$("#titleBar h2").css({"background-position":"left "+ $(this).attr("rel")})
				//
				$(".scrollNav").removeClass("active");
				$(this).addClass("active");
			});
		}
		//
		// Easy slider
/*		$("#slider1").easySlider({
			auto: false,
			continuous: true
		});
		$("#slider2").easySlider({
			auto: false,
			continuous: true
		});
		$("#slider3").easySlider({
			auto: false,
			continuous: true
		});
		$("#slider4").easySlider({
			auto: false,
			continuous: true
		});
		$("#slider5").easySlider({
			auto: false,
			continuous: true
		});
		$("#slider6").easySlider({
			auto: false,
			continuous: true
		});
		$("#slider7").easySlider({
			auto: false,
			continuous: true
		});*/
		// 
		// project bttn overlay
		/*$("div.entry ul a img").mouseover(function(){
			$(this).parent().next("div").css("display","block");
		})
		$("div.entry ul a").mouseout(function(){
			$(this).next("div").css("display","none");
		})*/
		// kill the project links for now
		$("div.overlay a").click(function(e){
			e.preventDefault();
		})
});
//
// fade callback function

fadeChange = function(){
	$("#titleBar h2").css({"background-position":"left "+ moveTo})
}
