// ImageCarousel-FixedInPage

// LIBRARY 
// BROWSER DETECTION
//IMAGE CAROUSEL

function ClassExpandablePS(strInstName){
	
	//client config
	this.strInstName = strInstName;
	this.Init = function() {

	    //add onclick
	    $j(".ExpandablePS .SectionTitle").click(function() {
	        var objSectionClicked = $j(this).parents(".Section")[0];

	        var isSectionClosed = (objSectionClicked.className.indexOf("Closed") != -1);
	        var objThisContent = $j(objSectionClicked).find(".ExpandableContentArea");
	        var objAccordian = $j(this).parents(".ExpandablePSAccordian")[0];

	        if (isSectionClosed) {
	            //close previously open item					
	            if (objAccordian) {
	                var objPrevious = $j(objAccordian).find(".Section").filter(":not(.Closed)").find(".ExpandableContentArea");
	                var objPrevousSection = $j(objPrevious).parents(".Section")[0];
	                $j(objPrevious).slideUp();
	                $j(objPrevousSection).addClass("Closed");
	            }
	            //open clicked item		
	            $j(objThisContent).slideDown();
	            $j(objSectionClicked).removeClass("Closed");
	        } else {
	            //close	clicked item
	            $j(objThisContent).slideUp();
	            $j(objSectionClicked).addClass("Closed");
	        }
	        return false;
	    });
	};
}

			