$(function(){
	$('#slides').slides({
		preload: true,
		preloadImage: 'templates/ea/images/slayt/loading.gif',
		play: 5000,
		pause: 2500,
		hoverPause: true,
		animationStart: function(current){
			$('.caption').animate({
				bottom:-35
				},100);
				if (window.console && console.log) {
					// example return of current slide number
					console.log('animationStart on slide: ', current);
				};
			},
			animationComplete: function(current){
			$('.caption').animate({
				bottom:0
			},200);
			if (window.console && console.log) {
				// example return of current slide number
				console.log('animationComplete on slide: ', current);
			};
		}
	});
	$('#mega-menu-tut').dcMegaMenu({
		rowItems: '2',
		speed: 'fast'
	});
	$('#sys_clock .lang_select').bind('mouseenter mouseleave', function() {
			$('div:eq(0)', this).slideToggle(150);
			$(this).toggleClass('hover');
	        num = $(this).hasClass('hover') ? $('a', this).size() : 1;
			$(this).stop(true, false).animate({ height: num * ($('a', this).height()+1) },200);
        });
	DD_roundies.addRule('.panel', '4px', true);
});
