$j("span.switch_thumb").click(function () {
$j("span.switch_thumb").toggleClass("swap");
$j("ul.display").fadeOut("fast", function() {
$j(this).fadeIn("fast").toggleClass("thumb_view").toggleClass("list");
// Undo equalized heights for list
$j('ul.list div.product-container').css("height","auto");
// Equalize all thumb heights on switch if list view default
var maxHeight = 0;
$j('ul.thumb_view div.product-container').each(function() { maxHeight = Math.max(maxHeight, $j(this).height()); }).height(maxHeight);
$j.cookie('view_State', $j('ul.display').is('.thumb_view') ? 'thumbs' : 'list' );
});
});
$j(container+" .smallFont").click(function(){
curSize=parseInt($j(target).css("font-size"));
newSize=curSize-2;
if(newSize>=minSize){
$j(target).css('font-size',newSize);
updatefontCookie(CookieName,newSize); //<-------moved here
}
if(newSize<=minSize){
$j(container+" .smallFont").addClass("sdisabled")
}
if(newSize<maxSize){
$j(container+" .largeFont").removeClass("ldisabled")
}
//<-------was here
});
$j(container+" .medFont").click(function(){
$j(target).css('font-size',medSize);
$j(container+" .smallFont").removeClass("sdisabled");
$j(container+" .largeFont").removeClass("ldisabled");
updatefontCookie(CookieName,medSize)
});
$j(container+" .largeFont").click(function(){
curSize=parseInt($j(target).css("font-size"));
newSize=curSize+2;
if(newSize<=(maxSize)){
$j(target).css('font-size',newSize)
updatefontCookie(CookieName,newSize); //<-------moved here
}
if(newSize>minSize){
$j(container+" .smallFont").removeClass("sdisabled")
}
if(newSize>=maxSize){
$j(container+" .largeFont").addClass("ldisabled")
}
//<-------was here
});
Time to create page: 0.079 seconds