From be97852e4060c003333bf61f5ae859389552d407 Mon Sep 17 00:00:00 2001 From: coderaiser Date: Sat, 10 May 2014 10:26:24 -0400 Subject: [PATCH] refactor(dom) lCurrent -> current --- lib/client/dom.js | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/lib/client/dom.js b/lib/client/dom.js index 1574ac9c..cf37d1af 100644 --- a/lib/client/dom.js +++ b/lib/client/dom.js @@ -945,8 +945,8 @@ var CloudCmd, Util, DOM, CloudFunc, Dialog; */ this.getCurrentMode = function(currentFile) { var ret, - lCurrent = currentFile || this.getCurrentFile(), - lMode = this.getByClass('mode', lCurrent); + current = currentFile || this.getCurrentFile(), + lMode = this.getByClass('mode', current); ret = lMode.textContent; return ret; @@ -973,9 +973,9 @@ var CloudCmd, Util, DOM, CloudFunc, Dialog; */ this.getCurrentFileContent = function(pParams, currentFile) { var ret, - lCurrentFile = currentFile ? currentFile : this.getCurrentFile(), + currentFile = currentFile ? currentFile : this.getCurrentFile(), lParams = pParams ? pParams : {}, - lPath = this.getCurrentPath(lCurrentFile), + lPath = this.getCurrentPath(currentFile), lErrorWas = pParams.error, lError = function(jqXHR) { Util.exec(lErrorWas); @@ -988,7 +988,7 @@ var CloudCmd, Util, DOM, CloudFunc, Dialog; lParams.error = lError; - if (this.isCurrentIsDir(lCurrentFile)) + if (this.isCurrentIsDir(currentFile)) lPath += '?json'; else if (!lParams.dataType) lParams.dataType = 'text'; @@ -1009,9 +1009,9 @@ var CloudCmd, Util, DOM, CloudFunc, Dialog; */ this.getCurrentData = function(callback, currentFile) { var hash, - lCurrentFile = currentFile ? currentFile : Cmd.getCurrentFile(), - path = DOM.getCurrentPath(lCurrentFile), - isDir = DOM.isCurrentIsDir(lCurrentFile), + currentFile = currentFile ? currentFile : Cmd.getCurrentFile(), + path = DOM.getCurrentPath(currentFile), + isDir = DOM.isCurrentIsDir(currentFile), func = function(data) { var length, @@ -1028,14 +1028,14 @@ var CloudCmd, Util, DOM, CloudFunc, Dialog; }; if (isDir) - DOM.getCurrentFileContent(func, lCurrentFile); + DOM.getCurrentFileContent(func, currentFile); else DOM.checkStorageHash(path, function(error, equal, hashNew) { Util.ifExec(!error && equal, function() { DOM.getDataFromStorage(path, callback); }, function() { hash = hashNew; - DOM.getCurrentFileContent(func, lCurrentFile); + DOM.getCurrentFileContent(func, currentFile); }); }); }; @@ -1314,8 +1314,8 @@ var CloudCmd, Util, DOM, CloudFunc, Dialog; * @param currentFile */ this.isCurrentIsDir = function(currentFile) { - var lCurrent = currentFile || this.getCurrentFile(), - lFileType = this.getByClass('mini-icon', lCurrent), + var current = currentFile || this.getCurrentFile(), + lFileType = this.getByClass('mini-icon', current), ret = this.isContainClass(lFileType, 'directory'); return ret; @@ -1341,8 +1341,8 @@ var CloudCmd, Util, DOM, CloudFunc, Dialog; * @param currentFile - current file by default */ this.getCurrentPath = function(currentFile) { - var lCurrent = currentFile || this.getCurrentFile(), - lPath = this.getCurrentLink( lCurrent ).href; + var current = currentFile || this.getCurrentFile(), + lPath = this.getCurrentLink( current ).href; lPath = decodeURI(lPath); /* убираем адрес хоста*/