Ticket #6170: 6170_5.patch

File 6170_5.patch, 2.2 KB (added by Sa'ar Zac Elias, 14 years ago)
  • _source/plugins/floatpanel/plugin.js

     
    282282                                                                }
    283283                                                        }
    284284
     285                                                        // Trigger the onHide event of the previously active panel to prevent
     286                                                        // incorrect styles from being applied (#6170)
     287                                                        var innerElement = element.getFirst(),
     288                                                                activePanel;
     289                                                        if ( ( activePanel = innerElement.getCustomData( 'activePanel' ) ) )
     290                                                                activePanel.onHide && activePanel.onHide.call( this, 1 );
     291                                                        innerElement.setCustomData( 'activePanel', this );
     292
    285293                                                        element.setStyles(
    286294                                                                {
    287295                                                                        top : top + 'px',
     
    315323                                        this.hideChild();
    316324                                        this.element.setStyle( 'display', 'none' );
    317325                                        this.visible = 0;
     326                                        this.element.getFirst().removeCustomData( 'activePanel' );
    318327                                }
    319328                        },
    320329
  • _source/plugins/panelbutton/plugin.js

     
    113113                                                        me.onOpen();
    114114                                        };
    115115
    116                                 panel.onHide = function()
     116                                panel.onHide = function( preventOnClose )
    117117                                        {
    118118                                                if ( me.className )
    119119                                                        this.element.getFirst().removeClass( me.className + '_panel' );
     
    122122
    123123                                                _.on = 0;
    124124
    125                                                 if ( me.onClose )
     125                                                if ( !preventOnClose && me.onClose )
    126126                                                        me.onClose();
    127127                                        };
    128128
  • _source/plugins/richcombo/plugin.js

     
    239239                                                me.onOpen();
    240240                                };
    241241
    242                         panel.onHide = function()
     242                        panel.onHide = function( preventOnClose )
    243243                                {
    244244                                        if ( me.className )
    245245                                                this.element.getFirst().removeClass( me.className + '_panel' );
     
    248248
    249249                                        me._.on = 0;
    250250
    251                                         if ( me.onClose )
     251                                        if ( !preventOnClose && me.onClose )
    252252                                                me.onClose();
    253253                                };
    254254
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy