// Place your application-specific JavaScript functions and classes here
// This file is automatically included by javascript_include_tag :defaults
//top.colorclasses = $A(["blindenmarkt", "operklosterneuburg", "steinway", "theaterfest", "juedischesmuseum"]);

top.colors = $A(["#57da00","#0086d7","#ff3333","#d008aa","#dbb500"]);
function switchcolor() {
	var nextcolor = top.colors.shift();
	top.colors.push(nextcolor);
	var cc = $$('.colorchanging');
	for(var i = 0; i < cc.length;i++) {
	  cc = new Effect.Morph(cc[i],{sync: false,style: { color: nextcolor }}); 
	}
//	new Effect.Parallel(cc,{duration: 0.8});
//	$$('.colorchanging').each(function(e) {
//		e.setStyle({color: nextcolor});
//	})
}	

function startswitch() { 
	switchcolor();	
	window.setInterval("switchcolor()",3000);
}


