1.  
  2. var collapseExpand = function(e) {
  3. if (DashboardManager) {
  4. tthis.setZIndex(++DashboardManager.zIndex);
  5. }
  6. if (tthis.getHeight() == tthis.HEIGHT) {
  7. var icon = minMaxBtn.getIcon();
  8. icon.setUri("./expandNoBorder.gif");
  9. var sizeAnimator = new BiSizeAnimator(tthis.getWidth(), tthis.HEIGHT, tthis.getWidth(), 35, BiSizeAnimator.SPEED5, false, BiComponentAnimation.CONSTANT_SPEED, tthis, 100);
  10. sizeAnimator.start();
  11. sizeAnimator.addEventListener("animationend", function(e) {this.dispose();});
  12. } else {
  13. var icon = minMaxBtn.getIcon();
  14. icon.setUri("./collapseNoBorder.gif");
  15. var sizeAnimator = new BiSizeAnimator(tthis.getWidth(), 35, tthis.getWidth(), tthis.HEIGHT, BiSizeAnimator.SPEED5, false, BiComponentAnimation.CONSTANT_SPEED, tthis, 100);
  16. sizeAnimator.start();
  17. sizeAnimator.addEventListener("animationend", function(e) {this.dispose();});
  18. }
  19. }
  20. minMaxBtn.addEventListener("click", collapseExpand);
  21.  
  22.