var map=new Object();map["aktuell"]=2000;map["projekt"]=5000;map["bewegungs"]=10000;map["termine"]=500;map["mitmachen"]=2000;map["veranstalter"]=4500;map["archiv"]=1200;map["kontakt"]=3600;map["impressum"]=1500;var mapmap=new Object();mapmap["news"]="aktuell";mapmap["project"]="projekt";mapmap["movement"]="bewegungs";mapmap["events"]="termine";mapmap["future"]="archiv";mapmap["participate"]="mitmachen";mapmap["about"]="veranstalter";mapmap["contact"]="kontakt";mapmap["disclaimer"]="impressum";function start(e){preview="http://images.websnapr.com/?size=s&key=bq5qXwS925sI&url="+encodeURI(this.href+"?"+hash);$("screen1").setProperty("src",preview);$("screen1").setStyles({"width":400,"opacity":0.5});$("screen2").setProperty("src",preview);$("screen2").setStyles({"width":400,"opacity":0.5});done=false;$each(map,function(_2,_3){if(this.href.contains(_3)&&proffekts[_3]){proffekts[_3](this);this.periodical=(proffekts[_3]).periodical(_2,"",this);done=true;}else{}},this);if(!done){$each(mapmap,function(_4,_5){if(this.href.contains(_5)&&proffekts[_4]){proffekts[_4](this);this.periodical=proffekts[_4].periodical(map[_4],"",this);done=true;}},this);}}function stop(e){if(this.fx){this.fx.stop();}if(this.fx1){this.fx1.stop();}if(this.t){this.t=undefined;}if(this.l){this.l=undefined;}$("screen1").setStyles({"opacity":0});$("screen2").setStyles({"opacity":0});$clear(this.periodical);}window.addEvent("load",function(){var _7=$$("#nav-main a");_7.each(function(_8){_8.addEvent("mouseenter",start.bindWithEvent(_8));_8.addEvent("mouseleave",stop.bindWithEvent(_8));});});var proffekts=new Object();proffekts.projekt=function(a){var _a=10;var _b=Math.floor(Math.random()*20);var _c=Math.floor(Math.random()*19);var _d=Fx.Transitions.linear;a.fx=new Fx.Styles("screen1",{duration:1000,wait:false,transition:_d}).start({"left":-1*_b+_a,"top":-1*_c+_a}).chain(function(){this.start({"left":_a,"top":_a});});};proffekts.bewegungs=function(a){var _f=Fx.Transitions.linear;a.fx=new Fx.Styles("screen1",{duration:5000,wait:false,transition:_f}).set({"width":600,"left":-300,"top":-100}).start({"width":650,"left":-400,"top":-250}).chain(function(){this.start({"width":600,"left":-300,"top":-100});});a.fx1=new Fx.Styles("screen2",{duration:5000,wait:false,transition:_f}).set({"width":650,"left":-400,"top":-140}).start({"width":600,"left":-300,"top":-225}).chain(function(){this.start({"width":600,"left":-300,"top":-140});});};proffekts.impressum=function(a){if(!a.t){$("screen1").setStyles({"top":0,"left":-30,"width":400});$("screen2").setStyles({"top":-0,"left":-80,"width":400});a.t=-20;}a.fx=new Fx.Styles("screen2",{duration:500,wait:false,transition:Fx.Transitions.linear}).start({"left":-80}).chain(function(){this.start({"left":0});}).chain(function(){this.start({"left":-30});});a.fx1=new Fx.Styles("screen1",{duration:400,wait:false,transition:Fx.Transitions.linear}).start({"left":-30}).chain(function(){this.start({"left":-120});}).chain(function(){this.start({"left":-80});});};proffekts.aktuell=function(a){var _12=Fx.Transitions.Elastic.easeInOut;var _13=Fx.Transitions.linear;a.fx=new Fx.Styles("screen1",{duration:1000,wait:false,transition:_13}).start({"left":-210,"top":-190}).chain(function(){this.start({"left":10,"top":10});});a.fx1=new Fx.Styles("screen2",{duration:10,wait:false,transition:_13}).start({"left":10,"top":10}).chain(function(){this.start({"left":-190,"top":-170});});};proffekts.termine=function(a){if(!a.t){a.t=0;$("screen1").setStyles({"left":0,"top":0});$("screen2").setStyles({"left":0,"top":$("screen1").getStyle("top")});a.fx2=new Fx.Styles("screen2",{duration:500,wait:false,transition:Fx.Transitions.linear});}var _15=Fx.Transitions.linear;a.fx=new Fx.Styles("screen1",{duration:500,wait:false,transition:_15}).start({"opacity":[0,1]});a.fx2.start({"left":[$("screen1").getStyle("left"),-10-a.t]});if(a.t<150){a.t+=5;}};proffekts.mitmachen=function(a){var _17=Fx.Transitions.linear;if(!a.t){$("screen1").setStyles({"top":-10,"left":0,"width":400});$("screen2").setStyles({"top":-100,"left":-80,"width":400});a.t=-20;}a.fx=new Fx.Styles("screen1",{duration:1000,wait:false,transition:_17}).start({"left":[0,-80],"opacity":0.8});a.fx.set.delay(1000,a.fx,{"top":a.t});a.fx.start.delay(1000,a.fx,{"left":0,"opacity":0});if(a.t>-100){a.t-=10;}else{a.t=0;}a.fx1=new Fx.Styles("screen2",{duration:1000,wait:false,transition:_17}).start({"left":[-80,0],"opacity":0});a.fx1.start.delay(1000,a.fx1,{"left":-80,"opacity":0.8});};proffekts.veranstalter=function(a){var _19=Fx.Transitions.Back.easeOut;if(!a.t){$("screen1").setStyles({"top":0,"left":-30,"width":400});$("screen1").setStyles({"width":400});a.t=-20;}$("screen2").setStyles({"top":-40+-2+Math.round(Math.random()*4)});$("screen2").setStyles({"left":-40+-2+Math.round(Math.random()*4)});a.fx=new Fx.Styles("screen1",{duration:500,wait:false,transition:_19}).start({"left":-80,"top":-40}).chain(function(){this.start({"left":-40,"top":-40});}).chain(function(){this.start({"left":-40,"top":-80});}).chain(function(){this.start({"left":-40,"top":-40});}).chain(function(){this.start({"left":0,"top":-40});}).chain(function(){this.start({"left":-40,"top":-40});}).chain(function(){this.start({"left":-40,"top":0});}).chain(function(){this.start({"left":-40,"top":-40});});};proffekts.kontakt=function(a){if(!a.t){$("screen1").setStyles({"top":-40,"left":-80,"width":400});$("screen2").setStyles({"top":-40,"left":0,"width":400});a.t=-20;}a.fx=new Fx.Styles("screen2",{duration:1000,wait:false,transition:Fx.Transitions.Quad.easeOut}).start({"left":-40});a.fx.start.delay(2600,a.fx,{"left":0});a.fx1=new Fx.Styles("screen1",{duration:1000,wait:false,transition:Fx.Transitions.Quad.easeOut});a.fx1.start.delay(800,a.fx1,{"left":-120});a.fx1.start.delay(1800,a.fx1,{"left":-80});};proffekts.archiv=function(a){if(!a.t){$("screen1").setStyles({"top":0,"left":-30,"opacity":0.6});$("screen2").setStyles({"top":0,"left":0});a.t=1;}$("screen1").setStyles.delay(600,$("screen1"),{"top":-120+Math.round(Math.random()*120),"left":-120+Math.round(Math.random()*120),"width":300+Math.round(Math.random()*200)});a.fx=new Fx.Styles("screen2",{duration:600,wait:false,transition:Fx.Transitions.linear}).start({"left":0,"top":0,"opacity":1});a.fx.start.delay(600,a.fx,{"opacity":0});};