/*
$Id: func.js,v 1.10 2008/11/06 16:53:56 max Exp $
vim: set ts=2 sw=2 sts=2 et:
*/

function fcIconsLIOver() {
  this.className += " over";
}

function fcIconsLIOut() {
  this.className = this.className.replace(/ over/, "");
}

//if ($.browser.msie) {
//  $.event.add(
//	  window,
//  	'load',
//	  function() {
//      $('ul.fancycat-icons-level-0 li').hover(fcIconsLIOver, fcIconsLIOut);
//  	}
//  );
//}

function fcIconsLIExpand() {
    $("#"+this.id+" + ul").show();
}

function fcIconsLICollapse() {
    $("#"+this.id+" + ul").hide();
}

$.event.add(
  window,
'load',
	function() {
		$('ul.fancycat-icons-level-0 li').each(function(){
				if (!$(this).hasClass("expanded")) {
					if ($("#"+this.id+" > ul").length > 0) {
						$("#"+this.id+" > ul").hide();
//						$("#"+this.id+" > a").toggle(fcIconsLIExpand, fcIconsLICollapse);
					}
//				} else {
//					if ($("#"+this.id+" > ul").length > 0) {
//						$("#"+this.id+" > a").toggle(fcIconsLICollapse, fcIconsLIExpand);
//					}
				}
			}
		);
	}
);
