/** Live : Placeholder du champ de recherche **/
var searchPlaceholder = new placeholder(document.getElementById("inputSearch"));

/** Live : menu Twitter/Facebook */
// Module Twitter
var twitterSearch = new lastTweetFeature({name: 'jean paul gaultier', lang: 'fr'});

// Accordion Socialize
var twitterMenu = new Accordion( 
{
	"handleEvent": "mouseover",
	"animate" : function(elm, value, callback)
	{
		var 
			_this = this,
			_indice = elm.getAttribute("data-accordion"),
			_elm = (elm) ? this.slides[_indice] : false
		;
		if (_elm)
		{
			var _value = ((!value) ? 0 : _elm.getAttribute("data-height") )+ "px";
			this.current["animations"] = driver.animateCSS(_elm, {"height" : _value}, 500, callback);
		}
	},
	"init": function()
	{
		var _elements = this.slides;
		for(var i=0, len=_elements.length; i<len; i++)
		{
			var _elm = _elements[i];
			if (!_elm.hasAttribute("data-height"))
			{
				_elm.setAttribute("data-height", _elm.offsetHeight);
			}
		}
		
		// Préselection de facebook
		this.activeItem(this.items[1], true);
	}
});

