REQUIRED INFORMATION

Ext version tested:

  • Ext 4.2.0 beta 2

Browser versions tested against:
  • Any

DOCTYPE tested against:
  • Any

Description:
  • A Portlet's doClose method doesn't return opacity to 1. It is actual if closeAction of a Portlet is "hide". A show call doesn't cause a Portlet to be actually appeared , because its opacity is 0.

Code:
doClose: function() {
    if (!this.closing) {
        this.closing = true;
        this.el.animate({
            opacity: 0,
            callback: function(){
                this.fireEvent('close', this);
                this[this.closeAction]();
            },
            scope: this
        });
    }
}
Steps to reproduce the problem:
  • Set a portlet's closeAction to "hide"
  • Close the portlet clicking its "X" tool
  • Call the portlet's show method

The result that was expected:
  • The Portlet appears

The result that occurs instead:
  • The Portlet does't appear (because of opacity is 0)

Test Case:

I will provide if you really need a sample.

HELPFUL INFORMATION

Possible fix:

  • Return opacity back to 1 in the animation callback if closeAction is "hide".

Code:
doClose : function () {
    if (!this.closing) {
        this.closing = true;
        this.el.animate({
            opacity  : 0,
            callback : function(){
                this.fireEvent('close', this);
                this[this.closeAction]();
                if(this.closeAction == "hide") {
                    this.el.setOpacity(1, false);
                }
            },
            scope : this
        });
    }
}