﻿$(function() {

    $('.menuadvices a').tooltip({
		track: true,
		delay: 0,
		showURL: false,
		left: -360,
		top: -40,
		showBody: " ++ ",
		fade: 500
	});

    $('.slider').innerfade({
        speed: 2000,
        timeout: 4000,
        type: 'sequence',
        containerheight: '197px',
		width: '571px'
    });

    $("input.search").focus(function() {
        $(this).val("");
    }).blur(function() {
        if ($(this).val() == "") {
            $(this).val($(this)[0].defaultValue);
        }
    });

	$("ul.textInfo").liScroll({ travelocity: 0.020 });
	
	/*Ajustement des hauteurs dans les colonnes centrales*/
	var heightRight = $("div.rightside").height();
	var heightLeftSide = $("div.leftside").height();
	var heightTags = (heightLeftSide - heightRight) + $("div.tags").height() ;
	
	if((heightLeftSide) <= heightRight) { 
		heightRight -= 275;
		$("div.contentside").height(heightRight);
	}
	else {	
		$("div.tags").height(heightTags);
	}
	
});
