$(document).ready(function(){
/* ### Beginn ### */
/* Slideshow */
        $('#imageContainer').cycle({
            fx:    'fade',
            speed:  5000
    });
        $('#imageContainerTirolmap').cycle({
            fx:    'fade',
            speed:  5000
    })
	
	
/* Themen Navigation Dropdown-Liste */
    $('div.topBlock').click(function () {
		$('ul.dropList').slideToggle(400);
    });
	$('ul.dropList').click(function () {
		$('ul.dropList').slideToggle(400);
    });
	$('.dropList li a').click(function(){ //select value from list
			var val = $(this).text();
			$('.topBlock').text(val);
		});


/* Banner Spezial Tipp */
	$('.bannerbox-spezial-hover').hide();
	$('.bannerbox-spezial').hover(
		// Hover In
		function() {
			$(this).next(".bannerbox-spezial-hover:first:hidden").fadeIn("slow");
		},
		// Hover Out
		function() {
			var element = $(this).next(".bannerbox-spezial-hover:first:visible");
			var time = 1000; // Time the div is visible (in milli sec.)
			var fade_out_function = function() { element.fadeOut("slow"); } // The function used for fading out
			var timeout = window.setTimeout(fade_out_function, time);
						
			element.hover(
				// Hover In
				function() {
					window.clearTimeout(timeout);
				},
				// Hover Out
				function() {
					timeout = window.setTimeout(fade_out_function, time);
				}
			);
		}
	);
/* ### Ende ### */
});
