[PE] [SSE] Optimization of right panel.
This commit is contained in:
parent
bfc91dc91f
commit
a7e603ca5f
|
@ -148,14 +148,15 @@ define([
|
|||
}
|
||||
}
|
||||
|
||||
var lastactive = -1, currentactive, priorityactive = -1;
|
||||
var lastactive = -1, currentactive, priorityactive = -1,
|
||||
activePane = this.rightmenu.GetActivePane();
|
||||
for (i=0; i<this._settings.length; i++) {
|
||||
var pnl = this._settings[i];
|
||||
if (pnl===undefined) continue;
|
||||
|
||||
if ( pnl.hidden ) {
|
||||
if (!pnl.btn.isDisabled()) pnl.btn.setDisabled(true);
|
||||
if (this.rightmenu.GetActivePane() == pnl.panelId)
|
||||
if (activePane == pnl.panelId)
|
||||
currentactive = -1;
|
||||
} else {
|
||||
if (pnl.btn.isDisabled()) pnl.btn.setDisabled(false);
|
||||
|
@ -165,7 +166,7 @@ define([
|
|||
pnl.needShow = false;
|
||||
priorityactive = i;
|
||||
} else if ( i != Common.Utils.documentSettingsType.Slide || this.rightmenu._settings[i].isCurrent) {
|
||||
if (this.rightmenu.GetActivePane() == pnl.panelId)
|
||||
if (activePane == pnl.panelId)
|
||||
currentactive = i;
|
||||
}
|
||||
|
||||
|
|
|
@ -254,7 +254,7 @@ define([
|
|||
},
|
||||
|
||||
GetActivePane: function() {
|
||||
return (this.minimizedMode) ? null : $(".settings-panel.active")[0].id;
|
||||
return (this.minimizedMode) ? null : this.$el.find(".settings-panel.active")[0].id;
|
||||
},
|
||||
|
||||
SetDisabled: function(id, disabled, all) {
|
||||
|
|
|
@ -177,7 +177,8 @@ define([
|
|||
this._settings[settingsType].hidden = 0;
|
||||
}
|
||||
|
||||
var lastactive = -1, currentactive, priorityactive = -1;
|
||||
var lastactive = -1, currentactive, priorityactive = -1,
|
||||
activePane = this.rightmenu.GetActivePane();
|
||||
for (i=0; i<this._settings.length; ++i) {
|
||||
var pnl = this._settings[i];
|
||||
if (pnl===undefined) continue;
|
||||
|
@ -185,7 +186,7 @@ define([
|
|||
if ( pnl.hidden ) {
|
||||
if ( !pnl.btn.isDisabled() )
|
||||
pnl.btn.setDisabled(true);
|
||||
if (this.rightmenu.GetActivePane() == pnl.panelId)
|
||||
if (activePane == pnl.panelId)
|
||||
currentactive = -1;
|
||||
} else {
|
||||
if ( pnl.btn.isDisabled() )
|
||||
|
@ -194,7 +195,7 @@ define([
|
|||
if ( pnl.needShow ) {
|
||||
pnl.needShow = false;
|
||||
priorityactive = i;
|
||||
} else if (this.rightmenu.GetActivePane() == pnl.panelId)
|
||||
} else if (activePane == pnl.panelId)
|
||||
currentactive = i;
|
||||
pnl.panel.setLocked(pnl.locked);
|
||||
}
|
||||
|
|
|
@ -234,7 +234,7 @@ define([
|
|||
},
|
||||
|
||||
GetActivePane: function() {
|
||||
return (this.minimizedMode) ? null : $(".settings-panel.active")[0].id;
|
||||
return (this.minimizedMode) ? null : this.$el.find(".settings-panel.active")[0].id;
|
||||
},
|
||||
|
||||
clearSelection: function() {
|
||||
|
|
Loading…
Reference in a new issue