/**
 * @author midj
 */

function toggleBlock(pEl){
	block = $(pEl).next();

	if(block.getStyle('display') == 'none'){
		new Effect.BlindDown(block,{duration: 0.2});
	}else{
		new Effect.BlindUp(block, {duration: 0.2});

	}
}

function buildSubmenu(pId){
	new Ajax.Updater('subnav', '/navbar/build?id=' + pId );

}

window.onload=function(){
	Nifty("div.agenda_div,div.news,div.newsletter_div,div.c_block");
	Nifty("div#right_content,div.b_block","big");
	var linput = $$('input', 'select', 'textarea');
	for(var i = 0;i < linput.length;i++){
		if (linput[i].getAttribute('type') == 'submit') {
	  }else{
	  	$(linput[i]).setAttribute('onFocus', '$(this).setStyle("border:4px solid #a2b8ef")');
	  	$(linput[i]).setAttribute('onBlur', '$(this).setStyle("border:4px solid #eaebec")');
	  }
	}
	for(var i = 1;i < 7;i++){
		if($('menu_' + i)){
			Menu.init("menu_" + i, {"orientation": Menu.HORIZONTAL, "hidePause": 0.5});
		}
	}
	setupZoom();
	/*var all_bullets = $$('a.bullet');
	for (var i = 0; i < all_bullets.length; i++) {
  	all_bullets[i].observe('click', function(event){
		  $('bullet_on').next().replace('<img alt="Bullet_on" src="/images/bullet_off.jpg"/>');
			//$('bullet_on').writeAttribute('id','')
			$(this).firstDescendant().replace('<img alt="Bullet_on" src="/images/bullet_on.jpg"/>');
			$(this).setAttribute('id','bullet_on')

			// -> '<ul id="favorite"><li>kiwi</li><li>banana</li><li>apple</li></ul>'

  	});
  }*/



//alert(linput.length);

}

