mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
MINOR Don't toggle CMS panels if state is already correct (to avoid the CMS UI doing three expensive redraw() invocation in its event listeners where one is sufficient)
This commit is contained in:
parent
7253746bdc
commit
d732a78852
@ -126,11 +126,15 @@
|
||||
this.trigger('toggle');
|
||||
},
|
||||
|
||||
expandPanel: function() {
|
||||
expandPanel: function(force) {
|
||||
if(!force && !this.hasClass('collapsed')) return;
|
||||
|
||||
this.togglePanel(true);
|
||||
},
|
||||
|
||||
collapsePanel: function() {
|
||||
collapsePanel: function(force) {
|
||||
if(!force && this.hasClass('collapsed')) return;
|
||||
|
||||
this.togglePanel(false);
|
||||
}
|
||||
});
|
||||
|
Loading…
x
Reference in New Issue
Block a user