feature(config) add localStorage

This commit is contained in:
coderaiser 2013-09-18 14:33:40 +00:00
parent 9c3a0cd079
commit 0634633101
2 changed files with 10 additions and 6 deletions

View file

@ -2,6 +2,7 @@
"api_url" : "/api/v1",
"appcache" : false,
"analytics" : true,
"localStorage" : true,
"minification" : {
"js" : true,
"css" : true,

View file

@ -211,12 +211,15 @@ var Util, DOM, CloudFunc, CloudCmd;
CloudCmd.KeysPanel = Listeners.initKeysPanel();
/* устанавливаем переменную доступности кэша */
Cache.setAllowed(true);
/* Устанавливаем кэш корневого каталога */
var lDirPath = DOM.getCurrentDirPath();
if (!Cache.get(lDirPath))
Cache.set(lDirPath, getJSONfromFileTable());
CloudCmd.getConfig(function(config) {
var localStorage = config.localStorage;
/* устанавливаем переменную доступности кэша */
Cache.setAllowed(localStorage);
/* Устанавливаем кэш корневого каталога */
var lDirPath = DOM.getCurrentDirPath();
if (!Cache.get(lDirPath))
Cache.set(lDirPath, getJSONfromFileTable());
});
});
/* выделяем строку с первым файлом */