﻿$(document).ready(function() {

	// Eventhandlers för mouseover/mouseout på
	// hotspots i carousel-bläddraren
	$("div.prev").live("mouseover", function() {
		if (jQuery.support.opacity) {
			$(this).fadeTo("fast", 1.0);
			$(this).siblings("div.next").fadeTo("fast", 0.0);
		}
		else {
			$(this).css("background-image", "url(images/Hotspot_left.png)");
			$(this).siblings("div.next").css("background-image", "url(images/Hotspot_transparent.gif)");
		}

	}).live("mouseout", function() {
		if (jQuery.support.opacity) {
			$(this).fadeTo("fast", 0.0);
		}
		else {
			$(this).css("background-image", "url(images/Hotspot_transparent.gif)");
		}
	});

	$("div.next").live("mouseover", function() {
		if (jQuery.support.opacity) {
			$(this).fadeTo("fast", 1.0);
			$(this).siblings("div.prev").fadeTo("fast", 0.0);
		}
		else {
			$(this).css("background-image", "url(images/Hotspot_right.png)");
			$(this).siblings("div.prev").css("background-image", "url(images/Hotspot_transparent.gif)");
		}
	}).live("mouseout", function() {
		if (jQuery.support.opacity) {
			$(this).fadeTo("fast", 0.0);
		}
		else {
			$(this).css("background-image", "url(images/Hotspot_transparent.gif)");
		}
	});

});

