$(document).ready(				  				  
				  
	function() {
	
	
		var n = $(".items div").length;
		// alert(n);
		$(".items").css("width", [n * 230] - 20 + "px");
		
		


				$("a.prev img").fadeTo(600,0.2);

				$("a.next img").fadeTo(600,0.2);

		
		$("a.prev").hover(
			function(){
			$("a.prev img").fadeTo(600,0.9);		  
			},
			function(){
			$("a.prev img").fadeTo(600,0.2);		  
			}
		);
		$("a.next").hover(
			function(){
			$("a.next img").fadeTo(600,0.9);		  
			},
			function(){
			$("a.next img").fadeTo(600,0.2);		  
			}
		);
		
		 // $("img").lazyload({      placeholder : "../images/grey.gif",     effect : "fadeIn" });



	$("#referenzen-preview").scrollable({
									   
	    // default size is 5 
    size: 4, 
     
    // set this to true when you want your items to be scrolled vertically 
    vertical: false, 
     
    // default scrolling time in milliseconds  
    speed: 300, 
     
    /*  
        default selector for nested element that will have  
        "move backwards" action automatically bind to it 
    */ 
    prev:'a.prev',         
     
    // default selector for "move onwards" action 
    next:'a.next',   
     
    // a flag whether scrolling starts over when last item is exceeded  
    loop: false,     

    /* 
        Items are selected by this selector. If none is found items will 
        be all elements that are directly nested under the root element  
    */ 
    items: '.items', 
     
    /* 
        A function that is triggered when items are scrolled. Inside this 
        function this- variable points to the current scrollable instance 
        and you can use it's API (described later) 
    */ 
    onSeek: null 								   
									   
	 });
		
	}

);

