/*
* collapsor (1.1) // 2009.02.27 // <http://plugins.jquery.com/project/collapsor>
* 
* REQUIRES jQuery 1.2.3+ <http://jquery.com/>
* 
* Copyright (c) 2008 TrafficBroker <http://www.trafficbroker.co.uk>
* Licensed under GPL and MIT licenses
* 
* @author    Jesus Carrera <jesus.carrera@trafficbroker.co.uk>
*/
(function(a){a.fn.collapsor=function(c){c=a.extend({},a.fn.collapsor.defaults,c);var b=this;return this.each(function(){a(this).find("+ "+c.sublevelElement).hide();if(a(this).hasClass(c.openClass)){a(this).find("+ "+c.sublevelElement).show()}a(this).click(function(){if(a(this).next().is(c.sublevelElement)){a(this).blur().toggleClass(c.openClass);if(c.closeOthers==true){a(this).parent().parent().children().find("."+c.openClass).not(this).removeClass(c.openClass).next().animate({height:"toggle",opacity:"toggle"},c.speed,c.easing)}a(this).next().animate({height:"toggle",opacity:"toggle"},c.speed,c.easing);return false}})})};a.fn.collapsor.defaults={openClass:"open",sublevelElement:"ul",closeOthers:true,speed:350,easing:"swing"}})(jQuery);