$(window).load(function() {
	$("#gallery_").attr("ml", $("#gallery_").width()-$("#gallery_").children().width());
	$("#pointL_").mouseover(function(){
		var l=-parseInt($(".carousel_", "#gallery_").css("left"));
		$(".carousel_", "#gallery_").animate({"left": 0}, l*5, "linear");	
	});
	$("#pointL_").mouseout(function(){
		$(".carousel_", "#gallery_").stop();	
	});
	$("#pointR_").mouseover(function(){
		var l=$(".carousel_", "#gallery_").width()-$("#gallery_").width()+parseInt($(".carousel_", "#gallery_").css("left"));
		$(".carousel_", "#gallery_").animate({"left": $("#gallery_").attr("ml")+"px"}, l*5, "linear");	
	});
	$("#pointR_").mouseout(function(){
		$(".carousel_", "#gallery_").stop();
	});
	$("img",".carousel_").click(function(){
	    var src = $(this).attr("src");
	    src = src.replace('/120/','/800/');
		$("img", ".nedv_photo").attr("src", src);
	});
});
