function fadeOut(el) { var attributes = { opacity: {to:0} }; var obj = new $Anim(el, attributes, 0.5); obj.onComplete.subscribe(function(){ //jslog.debug("calling fadeOut.onComplete()"); $Dom.replaceClass(el, "show", "hide"); //document.getElementById(el).style.display = "none"; //jslog.info("set "+el+"'s class to 'hide'"); }); obj.animate(); } function fadeIn(el) { var attributes = { opacity: {to:1} }; var obj = new $Anim(el, attributes, 0.5); obj.onComplete.subscribe(function(){ //jslog.debug("calling fadeIn.onComplete()"); $Dom.replaceClass(el, "hide", "show"); //document.getElementById(el).style.display = "block"; //jslog.info("set "+el+"'s class to 'show'"); }); obj.animate(); } function slideUp(el) { jslog.debug("el.style.height = "+$(el).style.height); var attributes = { height: {from:$(el).style.height, to:0, units:'pixels'} }; var obj = new $Anim(el, attributes, 0.5); obj.onComplete.subscribe(function(){ jslog.debug("calling slideUp.onComplete()"); }); obj.animate(); } var expandToggle = true; function windowExpand(el, img) { if(isMoz){ var attributes = (expandToggle != true)?{ maxHeight: {to:320} }:{ maxHeight: {to:620} }; } if(isIE){ var attributes = (expandToggle != true)?{ height: {to:320} }:{ height: {to:620} }; } jslog.error("el = "+el); jslog.error("attributes = "+attributes); var obj = new $Anim(el, attributes, 0.25, YAHOO.util.Easing.easeOut); obj.onComplete.subscribe(function(){ jslog.debug("windowExpand.onComplete()"); img.src = (expandToggle != true)?'images/menu_arrow_expand.gif':'images/menu_arrow_retract.gif'; jslog.warning("img.src = "+img.src); expandToggle = (expandToggle != true)?true:false; jslog.debug("expandToggle = "+expandToggle); }); obj.animate(); } function scrollResponse(el) { var attributes = { scroll: { to: [0, 0] } }; var obj = new YAHOO.util.Scroll(el, attributes, 0.5, YAHOO.util.Easing.easeOut); obj.onComplete.subscribe(function(){ jslog.debug("scrollResponse complete"); }); obj.animate(); jslog.warning("scrolling "+el+" to top"); jslog.warning(obj.isAnimated()); }