?? webdav.js
字號:
//=====================================================================================//===//=== WebDav controller//===//=====================================================================================ker.include('harvesting/webdav/model.js');ker.include('harvesting/webdav/view.js');var wd = new Object();//=====================================================================================function WebDav(xmlLoader){ //--- call super constructor Harvester.call(this); var loader= xmlLoader; var model = new wd.Model(loader); var view = new wd.View(loader); //--- public methods this.addGroupRow = addGroupRow; this.removeGroupRow = view.removeGroupRow; this.getResultTip = view.getResultTip; this.model = model; this.view = view;//=====================================================================================//===//=== API methods//===//=====================================================================================this.getType = function() { return "webdav"; }this.getLabel = function() { return loader.eval("info[@type='webdav']/long"); }this.getEditPanel = function() { return "wd.editPanel"; }//=====================================================================================this.init = function(){ this.view.init(); model.retrieveGroups (ker.wrap(this, init_groups_OK)); model.retrieveCategories(ker.wrap(this, init_categ_OK)); model.retrieveIcons (ker.wrap(this, init_icons_OK));}//-------------------------------------------------------------------------------------function init_groups_OK(data){ view.clearGroups(); for (var i=0; i<data.length; i++) view.addGroup(data[i].id, data[i].label[Env.lang]); }//-------------------------------------------------------------------------------------function init_categ_OK(data){ view.clearCategories(); for (var i=0; i<data.length; i++) view.addCategory(data[i].id, data[i].label[Env.lang]); }//-------------------------------------------------------------------------------------function init_icons_OK(data){ view.clearIcons(); for (var i=0; i<data.length; i++) view.addIcon(data[i]); }//=====================================================================================function addGroupRow(){ var groups = view.getSelectedGroups(); if (groups.length == 0) alert(loader.getText('pleaseSelectGroup')); else view.addEmptyGroupRows(groups);}//=====================================================================================}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -