// NAMESPACE DEFINITIONs
if (!$defined(GoalCom)) {var GoalCom={};}
if (!$defined(GoalCom.UI)) {GoalCom.UI={};}

// GOALCOM.UI.BASICMENU
GoalCom.UI.BasicMenu = new Class({
	options : {
		hoverClass : "i-hover",
		enableGrouping : true
	},
	
	initialize : function(el, options) {
		this.setOptions(options);
		
		this._el = $(el);
		
		// DOM SETUP
		$ES("li", this._el).each((function(item) {
			item.setStyle("width", item.getSize().size.x)
			.addEvent("mouseenter", (function() {
				this.el.addClass(this.hoverClass);
			}).bind({"el" : item, "hoverClass" : this.options.hoverClass}))
			.addEvent("mouseleave", (function() {
				this.el.removeClass(this.hoverClass);
			}).bind({"el" : item, "hoverClass" : this.options.hoverClass}))
		}).bind(this));
	}
});
GoalCom.UI.BasicMenu.implement(new Options);