mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-01-23 10:45:47 +00:00
refactor(dom) getPanel
This commit is contained in:
parent
e3e79062fd
commit
18594919e2
1 changed files with 12 additions and 12 deletions
|
|
@ -696,7 +696,7 @@ var CloudCmd, Util, DOM, CloudFunc, Dialog;
|
|||
* get not current direcotory path
|
||||
*/
|
||||
this.getNotCurrentDirPath = function() {
|
||||
var panel = this.getPanel(true),
|
||||
var panel = this.getPanel(),
|
||||
path = this.getCurrentDirPath(panel);
|
||||
|
||||
return path;
|
||||
|
|
@ -1405,12 +1405,12 @@ var CloudCmd, Util, DOM, CloudFunc, Dialog;
|
|||
/**
|
||||
* shows panel right or left (or active)
|
||||
*/
|
||||
this.showPanel = function(pActive) {
|
||||
var ret = true,
|
||||
lPanel = this.getPanel(pActive);
|
||||
this.showPanel = function(active) {
|
||||
var ret = true,
|
||||
panel = this.getPanel({active: active});
|
||||
|
||||
if (lPanel)
|
||||
this.show(lPanel);
|
||||
if (panel)
|
||||
this.show(panel);
|
||||
else
|
||||
ret = false;
|
||||
|
||||
|
|
@ -1420,12 +1420,12 @@ var CloudCmd, Util, DOM, CloudFunc, Dialog;
|
|||
/**
|
||||
* hides panel right or left (or active)
|
||||
*/
|
||||
this.hidePanel = function(pActive) {
|
||||
var ret = false,
|
||||
lPanel = this.getPanel(pActive);
|
||||
this.hidePanel = function(active) {
|
||||
var ret = false,
|
||||
panel = this.getPanel({active: active});
|
||||
|
||||
if (lPanel)
|
||||
ret = this.hide(lPanel);
|
||||
if (panel)
|
||||
ret = this.hide(panel);
|
||||
|
||||
return ret;
|
||||
};
|
||||
|
|
@ -1631,7 +1631,7 @@ var CloudCmd, Util, DOM, CloudFunc, Dialog;
|
|||
|
||||
DOM.Storage.remove(path, function() {
|
||||
var panel = DOM.getPanel(),
|
||||
panelPassive = DOM.getPanel(true),
|
||||
panelPassive = DOM.getPanel({active: false}),
|
||||
setCurrent = function() {
|
||||
var current = DOM.getCurrentByName(name);
|
||||
DOM.setCurrentFile(current);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue