jQuery(function(a){jQuery(function(a){a.supersized({autoplay:1,slideshow:1,min_width:900,min_height:600,performance:3,vertical_center:1,horizontal_center:1,slides:[{image:"media/img/bg6.jpg"},{image:"media/img/bg1.jpg"},{image:"media/img/bg2.jpg"},{image:"media/img/bg3.jpg"},{image:"media/img/bg4.jpg"},{image:"media/img/bg5.jpg"}]})})});$(document).ready(function(){function c(){a();b("Via della Fonderia, 1R Firenze")}function b(a){var b='<img src="media/img/logo_fondue.png" alt="La Fondue"/><br/><p style="font-family: Courier New; font-size: 14px; font-style: italic;">'+a+"</p>";if(geocoder){geocoder.getLatLng(a,function(c){if(!c){alert(a+" not found")}else{map.setCenter(c,15);var d=new GMarker(c,{draggable:false});map.addOverlay(d);GEvent.addListener(d,"click",function(){d.openInfoWindowHtml(b)});GEvent.trigger(d,"click")}})}}function a(){if(GBrowserIsCompatible()){map=new GMap2(document.getElementById("map_canvas"));map.setMapType(G_SATELLITE_MAP);map.setCenter(new GLatLng(43.7728383,11.2372869),17);map.setUIToDefault();geocoder=new GClientGeocoder}}map=null;geocoder=null;$(".thumb > a").fancybox({overlayColor:"#000000",overlayOpacity:"0.8",titlePosition:"over",onComplete:function(){$("#fancybox-img").loupe({width:200,height:150,loupe:"loupe"})}});current="home";$wh=$(window).height();$ww=$(window).width();$ph=$("#a-content > p").height()+10;$tHolder=$("#thumb-hld");$aCon=$("#a-content");$map=$("#map_cnt");$(window).resize(function(){$wh=$(window).height();$ww=$(window).width();$ph=$("#ap1").height()+10;if(current!=="ristorante"){$aCon.height($wh)}else{$aCon.height($ph)}});$("#ristorante").click(function(a){a.stopPropagation();switch(current){case"piatti":$tHolder.stop().fadeOut({complete:function(){$aCon.animate({height:$ph},{duration:1e3,easing:"linear",complete:function(){$("#ap1, #ap2, #ap3").stop().fadeIn()}})}});break;case"contatti":$map.stop().fadeOut({complete:function(){$aCon.stop().animate({height:$ph},{duration:1e3,easing:"linear",complete:function(){$("#ap1, #ap2, #ap3").stop().fadeIn()}})}});break;case"home":$aCon.stop().animate({height:$ph},{duration:1e3,easing:"linear",complete:function(){$("#ap1, #ap2, #ap3").stop().fadeIn()}})}$(".selected").removeClass("selected");$(this).addClass("selected");current="ristorante"});$("#piatti").click(function(a){a.stopPropagation();switch(current){case"ristorante":$("#ap1, #ap2, #ap3").stop().fadeOut({complete:function(){$aCon.stop().animate({height:$wh},{duration:1e3,easing:"linear",complete:function(){$tHolder.stop().fadeIn()}})}});break;case"contatti":$map.stop().fadeOut({complete:function(){$tHolder.stop().fadeIn()}});break;case"home":$aCon.stop().animate({height:$wh},{duration:1e3,easing:"linear",complete:function(){$tHolder.stop().fadeIn()}});break}$(".selected").removeClass("selected");$(this).addClass("selected");current="piatti"});$("#contatti").click(function(a){a.stopPropagation();a.preventDefault();switch(current){case"piatti":$tHolder.stop().fadeOut({complete:function(){$map.stop().fadeIn({complete:c()});setTimeout("map.checkResize()",2330)}});break;case"ristorante":$("#ap1, #ap2, #ap3").fadeOut({complete:function(){$aCon.stop().animate({height:$wh},{duration:1e3,easing:"linear",complete:function(){$map.stop().fadeIn({complete:c()});setTimeout("map.checkResize()",2330)}})}});break;case"home":$aCon.stop().animate({height:$wh},{duration:1e3,easing:"linear",complete:function(){$map.stop().fadeIn({complete:c()});setTimeout("map.checkResize()",2330)}});break}$(".selected").removeClass("selected");$(this).addClass("selected");current="contatti"});$("#logo").click(function(a){a.stopPropagation();switch(current){case"ristorante":$("#ap1, #ap2, #ap3").stop().fadeOut({complete:function(){$aCon.stop().animate({height:0},{duration:1e3,easing:"linear"})}});break;case"piatti":$tHolder.stop().fadeOut({complete:function(){$aCon.stop().animate({height:0},{duration:1e3,easing:"linear"})}});break;case"contatti":$map.stop().fadeOut({complete:function(){$aCon.stop().animate({height:0},{duration:1e3,easing:"linear"})}});break}current="home"})})
