From f7fc89f4a01bd4ded43a909ec7979e92e33cb75c Mon Sep 17 00:00:00 2001 From: coderaiser Date: Fri, 4 Apr 2014 06:26:29 -0400 Subject: [PATCH] refactor(config, consoke, key) rm unused vars --- lib/client/config.js | 2 +- lib/client/console.js | 3 +-- lib/client/key.js | 11 ++++------- 3 files changed, 6 insertions(+), 10 deletions(-) diff --git a/lib/client/config.js b/lib/client/config.js index fb9bc4a0..7984c16c 100644 --- a/lib/client/config.js +++ b/lib/client/config.js @@ -19,7 +19,7 @@ var CloudCmd, Util, DOM; Notify = DOM.Notify, Config = this; - function init(pCallBack) { + function init() { Loading = true; showLoad(); diff --git a/lib/client/console.js b/lib/client/console.js index a3db1294..3a5ae5e5 100644 --- a/lib/client/console.js +++ b/lib/client/console.js @@ -4,7 +4,7 @@ var CloudCmd, Util, DOM, CloudFunc, $; CloudCmd.Console = ConsoleProto; - function ConsoleProto(CallBack) { + function ConsoleProto() { var Name = 'Console', Buffer = { log : '', @@ -15,7 +15,6 @@ var CloudCmd, Util, DOM, CloudFunc, $; Element, MouseBinded, Socket, - Key = CloudCmd.Key, Images = DOM.Images, Notify = DOM.Notify, diff --git a/lib/client/key.js b/lib/client/key.js index 616dcdc8..dd8d7ad5 100644 --- a/lib/client/key.js +++ b/lib/client/key.js @@ -83,8 +83,7 @@ var CloudCmd, Util, DOM; function listener(pEvent) { /* получаем выдленный файл*/ - var i, n, - lKeyCode = pEvent.keyCode, + var lKeyCode = pEvent.keyCode, lAlt = pEvent.altKey, ctrl = pEvent.ctrlKey; /* если клавиши можно обрабатывать*/ @@ -112,12 +111,11 @@ var CloudCmd, Util, DOM; } function setCurrentByLetter(pKeyCode) { - var i, n, name, isCurrent, isMatch, byName, firstByName, + var i, n, name, isMatch, byName, firstByName, skipCount = 0, skipN = 0, setted = false, current = Info.element, - panel = Info.panel, files = Info.files, char = String.fromCharCode(pKeyCode), regExp = new RegExp('^' + char + '.*$', 'i'); @@ -162,11 +160,10 @@ var CloudCmd, Util, DOM; } function switchKey(pEvent) { - var i, n, id, obj, files, + var i, id, obj, files, current = Info.element, panel = Info.panel, path = Info.path, - dirPath = Info.dirPath, filesPassive = Info.filesPassive, prev = current.previousSibling, next = current.nextSibling, @@ -457,4 +454,4 @@ var CloudCmd, Util, DOM; } } -})(CloudCmd, Util, DOM); \ No newline at end of file +})(CloudCmd, Util, DOM);