diff --git a/api/js/webodf/template.odt b/collabeditor/assets/template.odt similarity index 100% rename from api/js/webodf/template.odt rename to collabeditor/assets/template.odt diff --git a/filemanager/js/collab.js b/collabeditor/js/app.js similarity index 87% rename from filemanager/js/collab.js rename to collabeditor/js/app.js index 81cdc790e8..00e5874cb7 100644 --- a/filemanager/js/collab.js +++ b/collabeditor/js/app.js @@ -1,28 +1,48 @@ /** - * EGroupware - Filemanager - Collab editor application object + * EGroupware - Collabeditor application object * * @link http://www.egroupware.org - * @package filemanager - * @author Hadi Nategh - * @copyright (c) 2016 Stylite AG + * @package Collabeditor + * @author Hadi Nategh + * @copyright (c) 2016 by Hadi Nategh * @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License * @version $Id$ */ /*egw:uses - /filemanager/js/collab_config.js; - /api/js/webodf/collab/dojo-amalgamation.js; - /api/js/webodf/collab/webodf.js; - /api/js/webodf/collab/wodocollabtexteditor.js; + /collabeditor/js/collab_config.js; + /collabeditor/js/webodf/collab/dojo-amalgamation.js; + /collabeditor/js/webodf/collab/webodf.js; + /collabeditor/js/webodf/collab/wodocollabtexteditor.js; /filemanager/js/app.js; */ +app.classes.filemanager = app.classes.filemanager.extend( +{ + + /** + * Function to check wheter selected file is editable. ATM only .odt is supported. + * + * @param {object} _egwAction egw action object + * @param {object} _senders object of selected row + * + * @returns {boolean} returns true if is editable otherwise false + */ + isEditable: function (_egwAction, _senders) { + if (_senders.length>1) return false; + var data = egw.dataGetUIDdata(_senders[0].id), + mime = this.et2._inst.widgetContainer.getWidgetById('$row'); + + return data.data.mime.match(mime.mime_odf_regex)?true:false; + } +}); + /** - * UI for filemanager collab + * UI for collabeditor * * @augments AppJS */ -app.classes.filemanager = app.classes.filemanager.extend({ +app.classes.collabeditor = AppJS.extend({ /* * @var editor odf editor object */ @@ -63,7 +83,7 @@ app.classes.filemanager = app.classes.filemanager.extend({ // call parent this._super.apply(this, arguments); - if (name == "filemanager.editor") + if (name == "collabeditor.editor") { // need to make body rock solid to avoid extra scrollbars jQuery('body').css({overflow:'hidden'}); @@ -103,11 +123,11 @@ app.classes.filemanager = app.classes.filemanager.extend({ { var self = this, isNew = window.location.href.search(/&path=/) == -1?true:false; - egw.json('filemanager.filemanager_collab.ajax_getGenesisUrl',[this.editor_getFilePath(), isNew], function (_data){ + egw.json('collabeditor.EGroupware\\collabeditor\\Ui.ajax_getGenesisUrl',[this.editor_getFilePath(), isNew], function (_data){ var serverOptions = { serverParams: { url:egw.link('/index.php?', { - menuaction: 'filemanager.filemanager_collab.poll' + menuaction: 'collabeditor.EGroupware\\collabeditor\\Ui.poll' }), genesisUrl:_data.genesis_url }, @@ -161,7 +181,7 @@ app.classes.filemanager = app.classes.filemanager.extend({ { leave(); } - egw.json('filemanager.filemanager_collab.ajax_actions',[{'es_id':this.collab_server.es_id, 'member_id':this.collab_server.memberid},'checkLastMember'], function(_isLastMember){ + egw.json('collabeditor.EGroupware\\collabeditor\\Ui.ajax_actions',[{'es_id':this.collab_server.es_id, 'member_id':this.collab_server.memberid},'checkLastMember'], function(_isLastMember){ if (_isLastMember) { var buttons = [ @@ -273,7 +293,7 @@ app.classes.filemanager = app.classes.filemanager.extend({ egw(window).message(egw.lang('Document %1 has been saved successfully.', file_path)); self.editor.setDocumentModified(false); if (_egwAction.id == 'saveas') return; - egw.json('filemanager.filemanager_collab.ajax_actions',[{'es_id':self.collab_server.es_id, 'file_path': egw.webserverUrl+'/webdav.php'+file_path}, 'save'], function(){ + egw.json('collabeditor.EGroupware\\collabeditor\\Ui.ajax_actions',[{'es_id':self.collab_server.es_id, 'file_path': egw.webserverUrl+'/webdav.php'+file_path}, 'save'], function(){ afterSaveCallback.call(self,{}); }).sendRequest(); }, @@ -507,7 +527,7 @@ app.classes.filemanager = app.classes.filemanager.extend({ self.collab_server = {server:server, memberid: memberId, es_id: sid}; if (Object.keys(self.editor).length == 0) { - Wodo.createCollabTextEditor('filemanager-editor_odfEditor', editorOptions, onEditorCreated); + Wodo.createCollabTextEditor('collabeditor-editor_odfEditor', editorOptions, onEditorCreated); } else { self.editor.joinSession(serverFactory.createSessionBackend(sid, _memberId, server), onEditing); } @@ -542,7 +562,7 @@ app.classes.filemanager = app.classes.filemanager.extend({ switch(_data.action) { case 'delete': - if (!_data.errs) egw.json('filemanager.filemanager_collab.ajax_actions', [{'es_id':this.collab_server.es_id}, 'delete'], function(){window.close();}).sendRequest(); + if (!_data.errs) egw.json('collabeditor.EGroupware\\collabeditor\\Ui.ajax_actions', [{'es_id':this.collab_server.es_id}, 'delete'], function(){window.close();}).sendRequest(); } }, @@ -567,7 +587,7 @@ app.classes.filemanager = app.classes.filemanager.extend({ { if (_btn == 'discard') { - egw.json('filemanager.filemanager_collab.ajax_actions',[{'es_id': self.collab_server.es_id}, 'discard'], function(){ + egw.json('collabeditor.EGroupware\\collabeditor\\Ui.ajax_actions',[{'es_id': self.collab_server.es_id}, 'discard'], function(){ self.collab_server.close = true; window.location.reload(); }).sendRequest(); diff --git a/filemanager/js/collab_config.js b/collabeditor/js/collab_config.js similarity index 75% rename from filemanager/js/collab_config.js rename to collabeditor/js/collab_config.js index 89ab8f19c3..c31881a9cf 100644 --- a/filemanager/js/collab_config.js +++ b/collabeditor/js/collab_config.js @@ -1,17 +1,17 @@ /** - * EGroupware - Filemanager - Collab editor - dojo configuration + * EGroupware - Collabeditor - dojo configuration * * @link http://www.egroupware.org - * @package filemanager - * @author Hadi Nategh - * @copyright (c) 2016 Stylite AG + * @package Collabeditor + * @author Hadi Nategh + * @copyright (c) 2016 by Hadi Nategh * @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License * @version $Id$ */ (function(){ // Dojo configuration needed for filemanager collab editor and // it should be load before app.js - var basedir = egw.webserverUrl+'/api/js/webodf/collab'; + var basedir = egw.webserverUrl+'/collabeditor/js/webodf/collab'; var usedLocale = "C"; if (navigator && navigator.language && navigator.language.match(/^(de)/)) { usedLocale = navigator.language.substr(0,2); diff --git a/api/js/webodf/AGPL-3.0.txt b/collabeditor/js/webodf/AGPL-3.0.txt similarity index 100% rename from api/js/webodf/AGPL-3.0.txt rename to collabeditor/js/webodf/AGPL-3.0.txt diff --git a/api/js/webodf/collab/EditorSession.js b/collabeditor/js/webodf/collab/EditorSession.js similarity index 100% rename from api/js/webodf/collab/EditorSession.js rename to collabeditor/js/webodf/collab/EditorSession.js diff --git a/api/js/webodf/collab/FullWindowZoomHelper.js b/collabeditor/js/webodf/collab/FullWindowZoomHelper.js similarity index 100% rename from api/js/webodf/collab/FullWindowZoomHelper.js rename to collabeditor/js/webodf/collab/FullWindowZoomHelper.js diff --git a/api/js/webodf/collab/MemberListView.js b/collabeditor/js/webodf/collab/MemberListView.js similarity index 100% rename from api/js/webodf/collab/MemberListView.js rename to collabeditor/js/webodf/collab/MemberListView.js diff --git a/api/js/webodf/collab/ServerFactory.js b/collabeditor/js/webodf/collab/ServerFactory.js similarity index 100% rename from api/js/webodf/collab/ServerFactory.js rename to collabeditor/js/webodf/collab/ServerFactory.js diff --git a/api/js/webodf/collab/SessionListView.js b/collabeditor/js/webodf/collab/SessionListView.js similarity index 100% rename from api/js/webodf/collab/SessionListView.js rename to collabeditor/js/webodf/collab/SessionListView.js diff --git a/api/js/webodf/collab/Tools.js b/collabeditor/js/webodf/collab/Tools.js similarity index 100% rename from api/js/webodf/collab/Tools.js rename to collabeditor/js/webodf/collab/Tools.js diff --git a/api/js/webodf/collab/Translator.js b/collabeditor/js/webodf/collab/Translator.js similarity index 100% rename from api/js/webodf/collab/Translator.js rename to collabeditor/js/webodf/collab/Translator.js diff --git a/api/js/webodf/collab/app/resources/app.css b/collabeditor/js/webodf/collab/app/resources/app.css similarity index 100% rename from api/js/webodf/collab/app/resources/app.css rename to collabeditor/js/webodf/collab/app/resources/app.css diff --git a/api/js/webodf/collab/avatar-joe.png b/collabeditor/js/webodf/collab/avatar-joe.png similarity index 100% rename from api/js/webodf/collab/avatar-joe.png rename to collabeditor/js/webodf/collab/avatar-joe.png diff --git a/api/js/webodf/collab/backend/Server.js b/collabeditor/js/webodf/collab/backend/Server.js similarity index 100% rename from api/js/webodf/collab/backend/Server.js rename to collabeditor/js/webodf/collab/backend/Server.js diff --git a/api/js/webodf/collab/backend/ServerFactory.js b/collabeditor/js/webodf/collab/backend/ServerFactory.js similarity index 100% rename from api/js/webodf/collab/backend/ServerFactory.js rename to collabeditor/js/webodf/collab/backend/ServerFactory.js diff --git a/api/js/webodf/collab/backend/jsglobal/OperationRouter.js b/collabeditor/js/webodf/collab/backend/jsglobal/OperationRouter.js similarity index 100% rename from api/js/webodf/collab/backend/jsglobal/OperationRouter.js rename to collabeditor/js/webodf/collab/backend/jsglobal/OperationRouter.js diff --git a/api/js/webodf/collab/backend/jsglobal/Server.js b/collabeditor/js/webodf/collab/backend/jsglobal/Server.js similarity index 100% rename from api/js/webodf/collab/backend/jsglobal/Server.js rename to collabeditor/js/webodf/collab/backend/jsglobal/Server.js diff --git a/api/js/webodf/collab/backend/jsglobal/ServerFactory.js b/collabeditor/js/webodf/collab/backend/jsglobal/ServerFactory.js similarity index 100% rename from api/js/webodf/collab/backend/jsglobal/ServerFactory.js rename to collabeditor/js/webodf/collab/backend/jsglobal/ServerFactory.js diff --git a/api/js/webodf/collab/backend/jsglobal/SessionBackend.js b/collabeditor/js/webodf/collab/backend/jsglobal/SessionBackend.js similarity index 100% rename from api/js/webodf/collab/backend/jsglobal/SessionBackend.js rename to collabeditor/js/webodf/collab/backend/jsglobal/SessionBackend.js diff --git a/api/js/webodf/collab/backend/jsglobal/SessionList.js b/collabeditor/js/webodf/collab/backend/jsglobal/SessionList.js similarity index 100% rename from api/js/webodf/collab/backend/jsglobal/SessionList.js rename to collabeditor/js/webodf/collab/backend/jsglobal/SessionList.js diff --git a/api/js/webodf/collab/backend/pullbox/OperationRouter.js b/collabeditor/js/webodf/collab/backend/pullbox/OperationRouter.js similarity index 100% rename from api/js/webodf/collab/backend/pullbox/OperationRouter.js rename to collabeditor/js/webodf/collab/backend/pullbox/OperationRouter.js diff --git a/api/js/webodf/collab/backend/pullbox/Server.js b/collabeditor/js/webodf/collab/backend/pullbox/Server.js similarity index 100% rename from api/js/webodf/collab/backend/pullbox/Server.js rename to collabeditor/js/webodf/collab/backend/pullbox/Server.js diff --git a/api/js/webodf/collab/backend/pullbox/ServerFactory.js b/collabeditor/js/webodf/collab/backend/pullbox/ServerFactory.js similarity index 100% rename from api/js/webodf/collab/backend/pullbox/ServerFactory.js rename to collabeditor/js/webodf/collab/backend/pullbox/ServerFactory.js diff --git a/api/js/webodf/collab/backend/pullbox/SessionBackend.js b/collabeditor/js/webodf/collab/backend/pullbox/SessionBackend.js similarity index 100% rename from api/js/webodf/collab/backend/pullbox/SessionBackend.js rename to collabeditor/js/webodf/collab/backend/pullbox/SessionBackend.js diff --git a/api/js/webodf/collab/backend/pullbox/SessionList.js b/collabeditor/js/webodf/collab/backend/pullbox/SessionList.js similarity index 100% rename from api/js/webodf/collab/backend/pullbox/SessionList.js rename to collabeditor/js/webodf/collab/backend/pullbox/SessionList.js diff --git a/api/js/webodf/collab/dijit/icons/commonIcons.css b/collabeditor/js/webodf/collab/dijit/icons/commonIcons.css similarity index 100% rename from api/js/webodf/collab/dijit/icons/commonIcons.css rename to collabeditor/js/webodf/collab/dijit/icons/commonIcons.css diff --git a/api/js/webodf/collab/dijit/icons/commonIcons_rtl.css b/collabeditor/js/webodf/collab/dijit/icons/commonIcons_rtl.css similarity index 100% rename from api/js/webodf/collab/dijit/icons/commonIcons_rtl.css rename to collabeditor/js/webodf/collab/dijit/icons/commonIcons_rtl.css diff --git a/api/js/webodf/collab/dijit/icons/editorIcons.css b/collabeditor/js/webodf/collab/dijit/icons/editorIcons.css similarity index 100% rename from api/js/webodf/collab/dijit/icons/editorIcons.css rename to collabeditor/js/webodf/collab/dijit/icons/editorIcons.css diff --git a/api/js/webodf/collab/dijit/icons/editorIcons_rtl.css b/collabeditor/js/webodf/collab/dijit/icons/editorIcons_rtl.css similarity index 100% rename from api/js/webodf/collab/dijit/icons/editorIcons_rtl.css rename to collabeditor/js/webodf/collab/dijit/icons/editorIcons_rtl.css diff --git a/api/js/webodf/collab/dijit/icons/images/commonIconsObjActDisabled.png b/collabeditor/js/webodf/collab/dijit/icons/images/commonIconsObjActDisabled.png similarity index 100% rename from api/js/webodf/collab/dijit/icons/images/commonIconsObjActDisabled.png rename to collabeditor/js/webodf/collab/dijit/icons/images/commonIconsObjActDisabled.png diff --git a/api/js/webodf/collab/dijit/icons/images/commonIconsObjActDisabled_rtl.png b/collabeditor/js/webodf/collab/dijit/icons/images/commonIconsObjActDisabled_rtl.png similarity index 100% rename from api/js/webodf/collab/dijit/icons/images/commonIconsObjActDisabled_rtl.png rename to collabeditor/js/webodf/collab/dijit/icons/images/commonIconsObjActDisabled_rtl.png diff --git a/api/js/webodf/collab/dijit/icons/images/commonIconsObjActEnabled.png b/collabeditor/js/webodf/collab/dijit/icons/images/commonIconsObjActEnabled.png similarity index 100% rename from api/js/webodf/collab/dijit/icons/images/commonIconsObjActEnabled.png rename to collabeditor/js/webodf/collab/dijit/icons/images/commonIconsObjActEnabled.png diff --git a/api/js/webodf/collab/dijit/icons/images/commonIconsObjActEnabled8bit.png b/collabeditor/js/webodf/collab/dijit/icons/images/commonIconsObjActEnabled8bit.png similarity index 100% rename from api/js/webodf/collab/dijit/icons/images/commonIconsObjActEnabled8bit.png rename to collabeditor/js/webodf/collab/dijit/icons/images/commonIconsObjActEnabled8bit.png diff --git a/api/js/webodf/collab/dijit/icons/images/commonIconsObjActEnabled8bit_rtl.png b/collabeditor/js/webodf/collab/dijit/icons/images/commonIconsObjActEnabled8bit_rtl.png similarity index 100% rename from api/js/webodf/collab/dijit/icons/images/commonIconsObjActEnabled8bit_rtl.png rename to collabeditor/js/webodf/collab/dijit/icons/images/commonIconsObjActEnabled8bit_rtl.png diff --git a/api/js/webodf/collab/dijit/icons/images/commonIconsObjActEnabled_rtl.png b/collabeditor/js/webodf/collab/dijit/icons/images/commonIconsObjActEnabled_rtl.png similarity index 100% rename from api/js/webodf/collab/dijit/icons/images/commonIconsObjActEnabled_rtl.png rename to collabeditor/js/webodf/collab/dijit/icons/images/commonIconsObjActEnabled_rtl.png diff --git a/api/js/webodf/collab/dijit/icons/images/editorIconsDisabled.png b/collabeditor/js/webodf/collab/dijit/icons/images/editorIconsDisabled.png similarity index 100% rename from api/js/webodf/collab/dijit/icons/images/editorIconsDisabled.png rename to collabeditor/js/webodf/collab/dijit/icons/images/editorIconsDisabled.png diff --git a/api/js/webodf/collab/dijit/icons/images/editorIconsDisabled_rtl.png b/collabeditor/js/webodf/collab/dijit/icons/images/editorIconsDisabled_rtl.png similarity index 100% rename from api/js/webodf/collab/dijit/icons/images/editorIconsDisabled_rtl.png rename to collabeditor/js/webodf/collab/dijit/icons/images/editorIconsDisabled_rtl.png diff --git a/api/js/webodf/collab/dijit/icons/images/editorIconsEnabled.png b/collabeditor/js/webodf/collab/dijit/icons/images/editorIconsEnabled.png similarity index 100% rename from api/js/webodf/collab/dijit/icons/images/editorIconsEnabled.png rename to collabeditor/js/webodf/collab/dijit/icons/images/editorIconsEnabled.png diff --git a/api/js/webodf/collab/dijit/icons/images/editorIconsEnabled_rtl.png b/collabeditor/js/webodf/collab/dijit/icons/images/editorIconsEnabled_rtl.png similarity index 100% rename from api/js/webodf/collab/dijit/icons/images/editorIconsEnabled_rtl.png rename to collabeditor/js/webodf/collab/dijit/icons/images/editorIconsEnabled_rtl.png diff --git a/api/js/webodf/collab/dijit/icons/images/loadingAnimation_rtl.gif b/collabeditor/js/webodf/collab/dijit/icons/images/loadingAnimation_rtl.gif similarity index 100% rename from api/js/webodf/collab/dijit/icons/images/loadingAnimation_rtl.gif rename to collabeditor/js/webodf/collab/dijit/icons/images/loadingAnimation_rtl.gif diff --git a/api/js/webodf/collab/dijit/themes/a11y/README.txt b/collabeditor/js/webodf/collab/dijit/themes/a11y/README.txt similarity index 100% rename from api/js/webodf/collab/dijit/themes/a11y/README.txt rename to collabeditor/js/webodf/collab/dijit/themes/a11y/README.txt diff --git a/api/js/webodf/collab/dijit/themes/a11y/colors3x4.png b/collabeditor/js/webodf/collab/dijit/themes/a11y/colors3x4.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/a11y/colors3x4.png rename to collabeditor/js/webodf/collab/dijit/themes/a11y/colors3x4.png diff --git a/api/js/webodf/collab/dijit/themes/a11y/colors7x10.png b/collabeditor/js/webodf/collab/dijit/themes/a11y/colors7x10.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/a11y/colors7x10.png rename to collabeditor/js/webodf/collab/dijit/themes/a11y/colors7x10.png diff --git a/api/js/webodf/collab/dijit/themes/a11y/indeterminate_progress.gif b/collabeditor/js/webodf/collab/dijit/themes/a11y/indeterminate_progress.gif similarity index 100% rename from api/js/webodf/collab/dijit/themes/a11y/indeterminate_progress.gif rename to collabeditor/js/webodf/collab/dijit/themes/a11y/indeterminate_progress.gif diff --git a/api/js/webodf/collab/dijit/themes/claro/Calendar.css b/collabeditor/js/webodf/collab/dijit/themes/claro/Calendar.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Calendar.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/Calendar.css diff --git a/api/js/webodf/collab/dijit/themes/claro/Calendar.less b/collabeditor/js/webodf/collab/dijit/themes/claro/Calendar.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Calendar.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/Calendar.less diff --git a/api/js/webodf/collab/dijit/themes/claro/Calendar_rtl.css b/collabeditor/js/webodf/collab/dijit/themes/claro/Calendar_rtl.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Calendar_rtl.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/Calendar_rtl.css diff --git a/api/js/webodf/collab/dijit/themes/claro/Calendar_rtl.less b/collabeditor/js/webodf/collab/dijit/themes/claro/Calendar_rtl.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Calendar_rtl.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/Calendar_rtl.less diff --git a/api/js/webodf/collab/dijit/themes/claro/ColorPalette.css b/collabeditor/js/webodf/collab/dijit/themes/claro/ColorPalette.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/ColorPalette.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/ColorPalette.css diff --git a/api/js/webodf/collab/dijit/themes/claro/ColorPalette.less b/collabeditor/js/webodf/collab/dijit/themes/claro/ColorPalette.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/ColorPalette.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/ColorPalette.less diff --git a/api/js/webodf/collab/dijit/themes/claro/Common.css b/collabeditor/js/webodf/collab/dijit/themes/claro/Common.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Common.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/Common.css diff --git a/api/js/webodf/collab/dijit/themes/claro/Common.less b/collabeditor/js/webodf/collab/dijit/themes/claro/Common.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Common.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/Common.less diff --git a/api/js/webodf/collab/dijit/themes/claro/Dialog.css b/collabeditor/js/webodf/collab/dijit/themes/claro/Dialog.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Dialog.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/Dialog.css diff --git a/api/js/webodf/collab/dijit/themes/claro/Dialog.less b/collabeditor/js/webodf/collab/dijit/themes/claro/Dialog.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Dialog.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/Dialog.less diff --git a/api/js/webodf/collab/dijit/themes/claro/Dialog_rtl.css b/collabeditor/js/webodf/collab/dijit/themes/claro/Dialog_rtl.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Dialog_rtl.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/Dialog_rtl.css diff --git a/api/js/webodf/collab/dijit/themes/claro/Dialog_rtl.less b/collabeditor/js/webodf/collab/dijit/themes/claro/Dialog_rtl.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Dialog_rtl.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/Dialog_rtl.less diff --git a/api/js/webodf/collab/dijit/themes/claro/Editor.css b/collabeditor/js/webodf/collab/dijit/themes/claro/Editor.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Editor.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/Editor.css diff --git a/api/js/webodf/collab/dijit/themes/claro/Editor.less b/collabeditor/js/webodf/collab/dijit/themes/claro/Editor.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Editor.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/Editor.less diff --git a/api/js/webodf/collab/dijit/themes/claro/Editor_rtl.css b/collabeditor/js/webodf/collab/dijit/themes/claro/Editor_rtl.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Editor_rtl.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/Editor_rtl.css diff --git a/api/js/webodf/collab/dijit/themes/claro/Editor_rtl.less b/collabeditor/js/webodf/collab/dijit/themes/claro/Editor_rtl.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Editor_rtl.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/Editor_rtl.less diff --git a/api/js/webodf/collab/dijit/themes/claro/InlineEditBox.css b/collabeditor/js/webodf/collab/dijit/themes/claro/InlineEditBox.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/InlineEditBox.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/InlineEditBox.css diff --git a/api/js/webodf/collab/dijit/themes/claro/InlineEditBox.less b/collabeditor/js/webodf/collab/dijit/themes/claro/InlineEditBox.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/InlineEditBox.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/InlineEditBox.less diff --git a/api/js/webodf/collab/dijit/themes/claro/Menu.css b/collabeditor/js/webodf/collab/dijit/themes/claro/Menu.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Menu.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/Menu.css diff --git a/api/js/webodf/collab/dijit/themes/claro/Menu.less b/collabeditor/js/webodf/collab/dijit/themes/claro/Menu.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Menu.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/Menu.less diff --git a/api/js/webodf/collab/dijit/themes/claro/Menu_rtl.css b/collabeditor/js/webodf/collab/dijit/themes/claro/Menu_rtl.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Menu_rtl.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/Menu_rtl.css diff --git a/api/js/webodf/collab/dijit/themes/claro/Menu_rtl.less b/collabeditor/js/webodf/collab/dijit/themes/claro/Menu_rtl.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Menu_rtl.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/Menu_rtl.less diff --git a/api/js/webodf/collab/dijit/themes/claro/ProgressBar.css b/collabeditor/js/webodf/collab/dijit/themes/claro/ProgressBar.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/ProgressBar.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/ProgressBar.css diff --git a/api/js/webodf/collab/dijit/themes/claro/ProgressBar.less b/collabeditor/js/webodf/collab/dijit/themes/claro/ProgressBar.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/ProgressBar.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/ProgressBar.less diff --git a/api/js/webodf/collab/dijit/themes/claro/README b/collabeditor/js/webodf/collab/dijit/themes/claro/README similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/README rename to collabeditor/js/webodf/collab/dijit/themes/claro/README diff --git a/api/js/webodf/collab/dijit/themes/claro/TimePicker.css b/collabeditor/js/webodf/collab/dijit/themes/claro/TimePicker.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/TimePicker.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/TimePicker.css diff --git a/api/js/webodf/collab/dijit/themes/claro/TimePicker.less b/collabeditor/js/webodf/collab/dijit/themes/claro/TimePicker.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/TimePicker.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/TimePicker.less diff --git a/api/js/webodf/collab/dijit/themes/claro/TimePicker_rtl.css b/collabeditor/js/webodf/collab/dijit/themes/claro/TimePicker_rtl.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/TimePicker_rtl.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/TimePicker_rtl.css diff --git a/api/js/webodf/collab/dijit/themes/claro/TimePicker_rtl.less b/collabeditor/js/webodf/collab/dijit/themes/claro/TimePicker_rtl.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/TimePicker_rtl.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/TimePicker_rtl.less diff --git a/api/js/webodf/collab/dijit/themes/claro/TitlePane.css b/collabeditor/js/webodf/collab/dijit/themes/claro/TitlePane.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/TitlePane.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/TitlePane.css diff --git a/api/js/webodf/collab/dijit/themes/claro/TitlePane.less b/collabeditor/js/webodf/collab/dijit/themes/claro/TitlePane.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/TitlePane.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/TitlePane.less diff --git a/api/js/webodf/collab/dijit/themes/claro/TitlePane_rtl.css b/collabeditor/js/webodf/collab/dijit/themes/claro/TitlePane_rtl.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/TitlePane_rtl.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/TitlePane_rtl.css diff --git a/api/js/webodf/collab/dijit/themes/claro/TitlePane_rtl.less b/collabeditor/js/webodf/collab/dijit/themes/claro/TitlePane_rtl.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/TitlePane_rtl.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/TitlePane_rtl.less diff --git a/api/js/webodf/collab/dijit/themes/claro/Toolbar.css b/collabeditor/js/webodf/collab/dijit/themes/claro/Toolbar.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Toolbar.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/Toolbar.css diff --git a/api/js/webodf/collab/dijit/themes/claro/Toolbar.less b/collabeditor/js/webodf/collab/dijit/themes/claro/Toolbar.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Toolbar.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/Toolbar.less diff --git a/api/js/webodf/collab/dijit/themes/claro/Toolbar_rtl.css b/collabeditor/js/webodf/collab/dijit/themes/claro/Toolbar_rtl.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Toolbar_rtl.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/Toolbar_rtl.css diff --git a/api/js/webodf/collab/dijit/themes/claro/Toolbar_rtl.less b/collabeditor/js/webodf/collab/dijit/themes/claro/Toolbar_rtl.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Toolbar_rtl.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/Toolbar_rtl.less diff --git a/api/js/webodf/collab/dijit/themes/claro/Tree.css b/collabeditor/js/webodf/collab/dijit/themes/claro/Tree.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Tree.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/Tree.css diff --git a/api/js/webodf/collab/dijit/themes/claro/Tree.less b/collabeditor/js/webodf/collab/dijit/themes/claro/Tree.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/Tree.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/Tree.less diff --git a/api/js/webodf/collab/dijit/themes/claro/claro.css b/collabeditor/js/webodf/collab/dijit/themes/claro/claro.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/claro.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/claro.css diff --git a/api/js/webodf/collab/dijit/themes/claro/claro_rtl.css b/collabeditor/js/webodf/collab/dijit/themes/claro/claro_rtl.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/claro_rtl.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/claro_rtl.css diff --git a/api/js/webodf/collab/dijit/themes/claro/compile.js b/collabeditor/js/webodf/collab/dijit/themes/claro/compile.js similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/compile.js rename to collabeditor/js/webodf/collab/dijit/themes/claro/compile.js diff --git a/api/js/webodf/collab/dijit/themes/claro/document.css b/collabeditor/js/webodf/collab/dijit/themes/claro/document.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/document.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/document.css diff --git a/api/js/webodf/collab/dijit/themes/claro/document.less b/collabeditor/js/webodf/collab/dijit/themes/claro/document.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/document.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/document.less diff --git a/api/js/webodf/collab/dijit/themes/claro/form/Button.css b/collabeditor/js/webodf/collab/dijit/themes/claro/form/Button.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/Button.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/Button.css diff --git a/api/js/webodf/collab/dijit/themes/claro/form/Button.less b/collabeditor/js/webodf/collab/dijit/themes/claro/form/Button.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/Button.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/Button.less diff --git a/api/js/webodf/collab/dijit/themes/claro/form/Button_rtl.css b/collabeditor/js/webodf/collab/dijit/themes/claro/form/Button_rtl.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/Button_rtl.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/Button_rtl.css diff --git a/api/js/webodf/collab/dijit/themes/claro/form/Button_rtl.less b/collabeditor/js/webodf/collab/dijit/themes/claro/form/Button_rtl.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/Button_rtl.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/Button_rtl.less diff --git a/api/js/webodf/collab/dijit/themes/claro/form/Checkbox.css b/collabeditor/js/webodf/collab/dijit/themes/claro/form/Checkbox.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/Checkbox.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/Checkbox.css diff --git a/api/js/webodf/collab/dijit/themes/claro/form/Checkbox.less b/collabeditor/js/webodf/collab/dijit/themes/claro/form/Checkbox.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/Checkbox.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/Checkbox.less diff --git a/api/js/webodf/collab/dijit/themes/claro/form/Common.css b/collabeditor/js/webodf/collab/dijit/themes/claro/form/Common.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/Common.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/Common.css diff --git a/api/js/webodf/collab/dijit/themes/claro/form/Common.less b/collabeditor/js/webodf/collab/dijit/themes/claro/form/Common.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/Common.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/Common.less diff --git a/api/js/webodf/collab/dijit/themes/claro/form/Common_rtl.css b/collabeditor/js/webodf/collab/dijit/themes/claro/form/Common_rtl.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/Common_rtl.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/Common_rtl.css diff --git a/api/js/webodf/collab/dijit/themes/claro/form/Common_rtl.less b/collabeditor/js/webodf/collab/dijit/themes/claro/form/Common_rtl.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/Common_rtl.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/Common_rtl.less diff --git a/api/js/webodf/collab/dijit/themes/claro/form/NumberSpinner.css b/collabeditor/js/webodf/collab/dijit/themes/claro/form/NumberSpinner.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/NumberSpinner.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/NumberSpinner.css diff --git a/api/js/webodf/collab/dijit/themes/claro/form/NumberSpinner.less b/collabeditor/js/webodf/collab/dijit/themes/claro/form/NumberSpinner.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/NumberSpinner.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/NumberSpinner.less diff --git a/api/js/webodf/collab/dijit/themes/claro/form/RadioButton.css b/collabeditor/js/webodf/collab/dijit/themes/claro/form/RadioButton.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/RadioButton.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/RadioButton.css diff --git a/api/js/webodf/collab/dijit/themes/claro/form/RadioButton.less b/collabeditor/js/webodf/collab/dijit/themes/claro/form/RadioButton.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/RadioButton.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/RadioButton.less diff --git a/api/js/webodf/collab/dijit/themes/claro/form/Select.css b/collabeditor/js/webodf/collab/dijit/themes/claro/form/Select.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/Select.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/Select.css diff --git a/api/js/webodf/collab/dijit/themes/claro/form/Select.less b/collabeditor/js/webodf/collab/dijit/themes/claro/form/Select.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/Select.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/Select.less diff --git a/api/js/webodf/collab/dijit/themes/claro/form/Slider.css b/collabeditor/js/webodf/collab/dijit/themes/claro/form/Slider.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/Slider.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/Slider.css diff --git a/api/js/webodf/collab/dijit/themes/claro/form/Slider.less b/collabeditor/js/webodf/collab/dijit/themes/claro/form/Slider.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/Slider.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/Slider.less diff --git a/api/js/webodf/collab/dijit/themes/claro/form/Slider_rtl.css b/collabeditor/js/webodf/collab/dijit/themes/claro/form/Slider_rtl.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/Slider_rtl.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/Slider_rtl.css diff --git a/api/js/webodf/collab/dijit/themes/claro/form/Slider_rtl.less b/collabeditor/js/webodf/collab/dijit/themes/claro/form/Slider_rtl.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/Slider_rtl.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/Slider_rtl.less diff --git a/api/js/webodf/collab/dijit/themes/claro/form/images/buttonArrows.png b/collabeditor/js/webodf/collab/dijit/themes/claro/form/images/buttonArrows.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/images/buttonArrows.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/images/buttonArrows.png diff --git a/api/js/webodf/collab/dijit/themes/claro/form/images/buttonDisabled.png b/collabeditor/js/webodf/collab/dijit/themes/claro/form/images/buttonDisabled.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/images/buttonDisabled.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/images/buttonDisabled.png diff --git a/api/js/webodf/collab/dijit/themes/claro/form/images/buttonDisabled.svg b/collabeditor/js/webodf/collab/dijit/themes/claro/form/images/buttonDisabled.svg similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/images/buttonDisabled.svg rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/images/buttonDisabled.svg diff --git a/api/js/webodf/collab/dijit/themes/claro/form/images/buttonEnabled.png b/collabeditor/js/webodf/collab/dijit/themes/claro/form/images/buttonEnabled.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/images/buttonEnabled.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/images/buttonEnabled.png diff --git a/api/js/webodf/collab/dijit/themes/claro/form/images/buttonEnabled.svg b/collabeditor/js/webodf/collab/dijit/themes/claro/form/images/buttonEnabled.svg similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/images/buttonEnabled.svg rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/images/buttonEnabled.svg diff --git a/api/js/webodf/collab/dijit/themes/claro/form/images/checkboxAndRadioButtons_IE6.png b/collabeditor/js/webodf/collab/dijit/themes/claro/form/images/checkboxAndRadioButtons_IE6.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/images/checkboxAndRadioButtons_IE6.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/images/checkboxAndRadioButtons_IE6.png diff --git a/api/js/webodf/collab/dijit/themes/claro/form/images/checkboxRadioButtonStates.png b/collabeditor/js/webodf/collab/dijit/themes/claro/form/images/checkboxRadioButtonStates.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/images/checkboxRadioButtonStates.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/images/checkboxRadioButtonStates.png diff --git a/api/js/webodf/collab/dijit/themes/claro/form/images/commonFormArrows.png b/collabeditor/js/webodf/collab/dijit/themes/claro/form/images/commonFormArrows.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/images/commonFormArrows.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/images/commonFormArrows.png diff --git a/api/js/webodf/collab/dijit/themes/claro/form/images/error.png b/collabeditor/js/webodf/collab/dijit/themes/claro/form/images/error.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/images/error.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/images/error.png diff --git a/api/js/webodf/collab/dijit/themes/claro/form/images/sliderThumbs.png b/collabeditor/js/webodf/collab/dijit/themes/claro/form/images/sliderThumbs.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/form/images/sliderThumbs.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/form/images/sliderThumbs.png diff --git a/api/js/webodf/collab/dijit/themes/claro/images/activeGradient.png b/collabeditor/js/webodf/collab/dijit/themes/claro/images/activeGradient.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/activeGradient.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/activeGradient.png diff --git a/api/js/webodf/collab/dijit/themes/claro/images/activeGradient.svg b/collabeditor/js/webodf/collab/dijit/themes/claro/images/activeGradient.svg similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/activeGradient.svg rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/activeGradient.svg diff --git a/api/js/webodf/collab/dijit/themes/claro/images/calendar.png b/collabeditor/js/webodf/collab/dijit/themes/claro/images/calendar.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/calendar.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/calendar.png diff --git a/api/js/webodf/collab/dijit/themes/claro/images/calendarArrows.png b/collabeditor/js/webodf/collab/dijit/themes/claro/images/calendarArrows.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/calendarArrows.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/calendarArrows.png diff --git a/api/js/webodf/collab/dijit/themes/claro/images/calendarArrows8bit.png b/collabeditor/js/webodf/collab/dijit/themes/claro/images/calendarArrows8bit.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/calendarArrows8bit.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/calendarArrows8bit.png diff --git a/api/js/webodf/collab/dijit/themes/claro/images/checkmarkNoBorder.gif b/collabeditor/js/webodf/collab/dijit/themes/claro/images/checkmarkNoBorder.gif similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/checkmarkNoBorder.gif rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/checkmarkNoBorder.gif diff --git a/api/js/webodf/collab/dijit/themes/claro/images/checkmarkNoBorder.png b/collabeditor/js/webodf/collab/dijit/themes/claro/images/checkmarkNoBorder.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/checkmarkNoBorder.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/checkmarkNoBorder.png diff --git a/api/js/webodf/collab/dijit/themes/claro/images/dialogCloseIcon.png b/collabeditor/js/webodf/collab/dijit/themes/claro/images/dialogCloseIcon.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/dialogCloseIcon.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/dialogCloseIcon.png diff --git a/api/js/webodf/collab/dijit/themes/claro/images/dialogCloseIcon8bit.png b/collabeditor/js/webodf/collab/dijit/themes/claro/images/dialogCloseIcon8bit.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/dialogCloseIcon8bit.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/dialogCloseIcon8bit.png diff --git a/api/js/webodf/collab/dijit/themes/claro/images/dnd.png b/collabeditor/js/webodf/collab/dijit/themes/claro/images/dnd.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/dnd.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/dnd.png diff --git a/api/js/webodf/collab/dijit/themes/claro/images/loadingAnimation.gif b/collabeditor/js/webodf/collab/dijit/themes/claro/images/loadingAnimation.gif similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/loadingAnimation.gif rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/loadingAnimation.gif diff --git a/api/js/webodf/collab/dijit/themes/claro/images/progressBarAnim.gif b/collabeditor/js/webodf/collab/dijit/themes/claro/images/progressBarAnim.gif similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/progressBarAnim.gif rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/progressBarAnim.gif diff --git a/api/js/webodf/collab/dijit/themes/claro/images/progressBarFull.png b/collabeditor/js/webodf/collab/dijit/themes/claro/images/progressBarFull.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/progressBarFull.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/progressBarFull.png diff --git a/api/js/webodf/collab/dijit/themes/claro/images/spriteArrows.png b/collabeditor/js/webodf/collab/dijit/themes/claro/images/spriteArrows.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/spriteArrows.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/spriteArrows.png diff --git a/api/js/webodf/collab/dijit/themes/claro/images/standardGradient.png b/collabeditor/js/webodf/collab/dijit/themes/claro/images/standardGradient.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/standardGradient.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/standardGradient.png diff --git a/api/js/webodf/collab/dijit/themes/claro/images/standardGradient.svg b/collabeditor/js/webodf/collab/dijit/themes/claro/images/standardGradient.svg similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/standardGradient.svg rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/standardGradient.svg diff --git a/api/js/webodf/collab/dijit/themes/claro/images/tooltip.png b/collabeditor/js/webodf/collab/dijit/themes/claro/images/tooltip.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/tooltip.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/tooltip.png diff --git a/api/js/webodf/collab/dijit/themes/claro/images/tooltip8bit.png b/collabeditor/js/webodf/collab/dijit/themes/claro/images/tooltip8bit.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/tooltip8bit.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/tooltip8bit.png diff --git a/api/js/webodf/collab/dijit/themes/claro/images/treeExpandImages.png b/collabeditor/js/webodf/collab/dijit/themes/claro/images/treeExpandImages.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/treeExpandImages.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/treeExpandImages.png diff --git a/api/js/webodf/collab/dijit/themes/claro/images/treeExpandImages8bit.png b/collabeditor/js/webodf/collab/dijit/themes/claro/images/treeExpandImages8bit.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/images/treeExpandImages8bit.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/images/treeExpandImages8bit.png diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/AccordionContainer.css b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/AccordionContainer.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/AccordionContainer.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/AccordionContainer.css diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/AccordionContainer.less b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/AccordionContainer.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/AccordionContainer.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/AccordionContainer.less diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/BorderContainer.css b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/BorderContainer.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/BorderContainer.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/BorderContainer.css diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/BorderContainer.less b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/BorderContainer.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/BorderContainer.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/BorderContainer.less diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/ContentPane.css b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/ContentPane.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/ContentPane.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/ContentPane.css diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/ContentPane.less b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/ContentPane.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/ContentPane.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/ContentPane.less diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/TabContainer.css b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/TabContainer.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/TabContainer.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/TabContainer.css diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/TabContainer.less b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/TabContainer.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/TabContainer.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/TabContainer.less diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/TabContainer_rtl.css b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/TabContainer_rtl.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/TabContainer_rtl.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/TabContainer_rtl.css diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/TabContainer_rtl.less b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/TabContainer_rtl.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/TabContainer_rtl.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/TabContainer_rtl.less diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/images/tabBottomSelected.png b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabBottomSelected.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/images/tabBottomSelected.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabBottomSelected.png diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/images/tabBottomSelected.svg b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabBottomSelected.svg similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/images/tabBottomSelected.svg rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabBottomSelected.svg diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/images/tabBottomUnselected.png b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabBottomUnselected.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/images/tabBottomUnselected.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabBottomUnselected.png diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/images/tabBottomUnselected.svg b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabBottomUnselected.svg similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/images/tabBottomUnselected.svg rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabBottomUnselected.svg diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/images/tabClose.png b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabClose.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/images/tabClose.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabClose.png diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/images/tabLeftSelected.png b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabLeftSelected.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/images/tabLeftSelected.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabLeftSelected.png diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/images/tabLeftSelected.svg b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabLeftSelected.svg similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/images/tabLeftSelected.svg rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabLeftSelected.svg diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/images/tabLeftUnselected.png b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabLeftUnselected.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/images/tabLeftUnselected.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabLeftUnselected.png diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/images/tabLeftUnselected.svg b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabLeftUnselected.svg similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/images/tabLeftUnselected.svg rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabLeftUnselected.svg diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/images/tabNested.png b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabNested.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/images/tabNested.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabNested.png diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/images/tabRightSelected.png b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabRightSelected.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/images/tabRightSelected.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabRightSelected.png diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/images/tabRightSelected.svg b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabRightSelected.svg similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/images/tabRightSelected.svg rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabRightSelected.svg diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/images/tabRightUnselected.png b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabRightUnselected.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/images/tabRightUnselected.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabRightUnselected.png diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/images/tabRightUnselected.svg b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabRightUnselected.svg similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/images/tabRightUnselected.svg rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabRightUnselected.svg diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/images/tabTopSelected.png b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabTopSelected.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/images/tabTopSelected.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabTopSelected.png diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/images/tabTopSelected.svg b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabTopSelected.svg similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/images/tabTopSelected.svg rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabTopSelected.svg diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/images/tabTopUnselected.png b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabTopUnselected.png similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/images/tabTopUnselected.png rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabTopUnselected.png diff --git a/api/js/webodf/collab/dijit/themes/claro/layout/images/tabTopUnselected.svg b/collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabTopUnselected.svg similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/layout/images/tabTopUnselected.svg rename to collabeditor/js/webodf/collab/dijit/themes/claro/layout/images/tabTopUnselected.svg diff --git a/api/js/webodf/collab/dijit/themes/claro/variables.css b/collabeditor/js/webodf/collab/dijit/themes/claro/variables.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/variables.css rename to collabeditor/js/webodf/collab/dijit/themes/claro/variables.css diff --git a/api/js/webodf/collab/dijit/themes/claro/variables.less b/collabeditor/js/webodf/collab/dijit/themes/claro/variables.less similarity index 100% rename from api/js/webodf/collab/dijit/themes/claro/variables.less rename to collabeditor/js/webodf/collab/dijit/themes/claro/variables.less diff --git a/api/js/webodf/collab/dijit/themes/dijit.css b/collabeditor/js/webodf/collab/dijit/themes/dijit.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/dijit.css rename to collabeditor/js/webodf/collab/dijit/themes/dijit.css diff --git a/api/js/webodf/collab/dijit/themes/dijit_rtl.css b/collabeditor/js/webodf/collab/dijit/themes/dijit_rtl.css similarity index 100% rename from api/js/webodf/collab/dijit/themes/dijit_rtl.css rename to collabeditor/js/webodf/collab/dijit/themes/dijit_rtl.css diff --git a/api/js/webodf/collab/dojo-amalgamation.js b/collabeditor/js/webodf/collab/dojo-amalgamation.js similarity index 100% rename from api/js/webodf/collab/dojo-amalgamation.js rename to collabeditor/js/webodf/collab/dojo-amalgamation.js diff --git a/api/js/webodf/collab/dojo/resources/LICENSE b/collabeditor/js/webodf/collab/dojo/resources/LICENSE similarity index 100% rename from api/js/webodf/collab/dojo/resources/LICENSE rename to collabeditor/js/webodf/collab/dojo/resources/LICENSE diff --git a/api/js/webodf/collab/dojo/resources/blank.gif b/collabeditor/js/webodf/collab/dojo/resources/blank.gif similarity index 100% rename from api/js/webodf/collab/dojo/resources/blank.gif rename to collabeditor/js/webodf/collab/dojo/resources/blank.gif diff --git a/api/js/webodf/collab/dojo/resources/blank.html b/collabeditor/js/webodf/collab/dojo/resources/blank.html similarity index 100% rename from api/js/webodf/collab/dojo/resources/blank.html rename to collabeditor/js/webodf/collab/dojo/resources/blank.html diff --git a/api/js/webodf/collab/dojo/resources/dnd.css b/collabeditor/js/webodf/collab/dojo/resources/dnd.css similarity index 100% rename from api/js/webodf/collab/dojo/resources/dnd.css rename to collabeditor/js/webodf/collab/dojo/resources/dnd.css diff --git a/api/js/webodf/collab/dojo/resources/dojo.css b/collabeditor/js/webodf/collab/dojo/resources/dojo.css similarity index 100% rename from api/js/webodf/collab/dojo/resources/dojo.css rename to collabeditor/js/webodf/collab/dojo/resources/dojo.css diff --git a/api/js/webodf/collab/dojo/resources/iframe_history.html b/collabeditor/js/webodf/collab/dojo/resources/iframe_history.html similarity index 100% rename from api/js/webodf/collab/dojo/resources/iframe_history.html rename to collabeditor/js/webodf/collab/dojo/resources/iframe_history.html diff --git a/api/js/webodf/collab/dojo/resources/images/dndCopy.png b/collabeditor/js/webodf/collab/dojo/resources/images/dndCopy.png similarity index 100% rename from api/js/webodf/collab/dojo/resources/images/dndCopy.png rename to collabeditor/js/webodf/collab/dojo/resources/images/dndCopy.png diff --git a/api/js/webodf/collab/dojo/resources/images/dndMove.png b/collabeditor/js/webodf/collab/dojo/resources/images/dndMove.png similarity index 100% rename from api/js/webodf/collab/dojo/resources/images/dndMove.png rename to collabeditor/js/webodf/collab/dojo/resources/images/dndMove.png diff --git a/api/js/webodf/collab/dojo/resources/images/dndNoCopy.png b/collabeditor/js/webodf/collab/dojo/resources/images/dndNoCopy.png similarity index 100% rename from api/js/webodf/collab/dojo/resources/images/dndNoCopy.png rename to collabeditor/js/webodf/collab/dojo/resources/images/dndNoCopy.png diff --git a/api/js/webodf/collab/dojo/resources/images/dndNoMove.png b/collabeditor/js/webodf/collab/dojo/resources/images/dndNoMove.png similarity index 100% rename from api/js/webodf/collab/dojo/resources/images/dndNoMove.png rename to collabeditor/js/webodf/collab/dojo/resources/images/dndNoMove.png diff --git a/api/js/webodf/collab/dojox/layout/resources/DndGridContainer.css b/collabeditor/js/webodf/collab/dojox/layout/resources/DndGridContainer.css similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/DndGridContainer.css rename to collabeditor/js/webodf/collab/dojox/layout/resources/DndGridContainer.css diff --git a/api/js/webodf/collab/dojox/layout/resources/ExpandoPane.css b/collabeditor/js/webodf/collab/dojox/layout/resources/ExpandoPane.css similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/ExpandoPane.css rename to collabeditor/js/webodf/collab/dojox/layout/resources/ExpandoPane.css diff --git a/api/js/webodf/collab/dojox/layout/resources/ExpandoPane.html b/collabeditor/js/webodf/collab/dojox/layout/resources/ExpandoPane.html similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/ExpandoPane.html rename to collabeditor/js/webodf/collab/dojox/layout/resources/ExpandoPane.html diff --git a/api/js/webodf/collab/dojox/layout/resources/FloatingPane.css b/collabeditor/js/webodf/collab/dojox/layout/resources/FloatingPane.css similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/FloatingPane.css rename to collabeditor/js/webodf/collab/dojox/layout/resources/FloatingPane.css diff --git a/api/js/webodf/collab/dojox/layout/resources/FloatingPane.html b/collabeditor/js/webodf/collab/dojox/layout/resources/FloatingPane.html similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/FloatingPane.html rename to collabeditor/js/webodf/collab/dojox/layout/resources/FloatingPane.html diff --git a/api/js/webodf/collab/dojox/layout/resources/GridContainer.css b/collabeditor/js/webodf/collab/dojox/layout/resources/GridContainer.css similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/GridContainer.css rename to collabeditor/js/webodf/collab/dojox/layout/resources/GridContainer.css diff --git a/api/js/webodf/collab/dojox/layout/resources/GridContainer.html b/collabeditor/js/webodf/collab/dojox/layout/resources/GridContainer.html similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/GridContainer.html rename to collabeditor/js/webodf/collab/dojox/layout/resources/GridContainer.html diff --git a/api/js/webodf/collab/dojox/layout/resources/RadioGroup.css b/collabeditor/js/webodf/collab/dojox/layout/resources/RadioGroup.css similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/RadioGroup.css rename to collabeditor/js/webodf/collab/dojox/layout/resources/RadioGroup.css diff --git a/api/js/webodf/collab/dojox/layout/resources/ResizeHandle.css b/collabeditor/js/webodf/collab/dojox/layout/resources/ResizeHandle.css similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/ResizeHandle.css rename to collabeditor/js/webodf/collab/dojox/layout/resources/ResizeHandle.css diff --git a/api/js/webodf/collab/dojox/layout/resources/RotatorContainer.css b/collabeditor/js/webodf/collab/dojox/layout/resources/RotatorContainer.css similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/RotatorContainer.css rename to collabeditor/js/webodf/collab/dojox/layout/resources/RotatorContainer.css diff --git a/api/js/webodf/collab/dojox/layout/resources/ScrollPane.css b/collabeditor/js/webodf/collab/dojox/layout/resources/ScrollPane.css similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/ScrollPane.css rename to collabeditor/js/webodf/collab/dojox/layout/resources/ScrollPane.css diff --git a/api/js/webodf/collab/dojox/layout/resources/ScrollPane.html b/collabeditor/js/webodf/collab/dojox/layout/resources/ScrollPane.html similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/ScrollPane.html rename to collabeditor/js/webodf/collab/dojox/layout/resources/ScrollPane.html diff --git a/api/js/webodf/collab/dojox/layout/resources/ToggleSplitter.css b/collabeditor/js/webodf/collab/dojox/layout/resources/ToggleSplitter.css similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/ToggleSplitter.css rename to collabeditor/js/webodf/collab/dojox/layout/resources/ToggleSplitter.css diff --git a/api/js/webodf/collab/dojox/layout/resources/icons/gridcontainer_grip.gif b/collabeditor/js/webodf/collab/dojox/layout/resources/icons/gridcontainer_grip.gif similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/icons/gridcontainer_grip.gif rename to collabeditor/js/webodf/collab/dojox/layout/resources/icons/gridcontainer_grip.gif diff --git a/api/js/webodf/collab/dojox/layout/resources/icons/grip_bg.gif b/collabeditor/js/webodf/collab/dojox/layout/resources/icons/grip_bg.gif similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/icons/grip_bg.gif rename to collabeditor/js/webodf/collab/dojox/layout/resources/icons/grip_bg.gif diff --git a/api/js/webodf/collab/dojox/layout/resources/icons/pixel.gif b/collabeditor/js/webodf/collab/dojox/layout/resources/icons/pixel.gif similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/icons/pixel.gif rename to collabeditor/js/webodf/collab/dojox/layout/resources/icons/pixel.gif diff --git a/api/js/webodf/collab/dojox/layout/resources/icons/resize.png b/collabeditor/js/webodf/collab/dojox/layout/resources/icons/resize.png similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/icons/resize.png rename to collabeditor/js/webodf/collab/dojox/layout/resources/icons/resize.png diff --git a/api/js/webodf/collab/dojox/layout/resources/icons/resizeRtl.png b/collabeditor/js/webodf/collab/dojox/layout/resources/icons/resizeRtl.png similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/icons/resizeRtl.png rename to collabeditor/js/webodf/collab/dojox/layout/resources/icons/resizeRtl.png diff --git a/api/js/webodf/collab/dojox/layout/resources/icons/rotator.png b/collabeditor/js/webodf/collab/dojox/layout/resources/icons/rotator.png similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/icons/rotator.png rename to collabeditor/js/webodf/collab/dojox/layout/resources/icons/rotator.png diff --git a/api/js/webodf/collab/dojox/layout/resources/icons/splitterToggleH.png b/collabeditor/js/webodf/collab/dojox/layout/resources/icons/splitterToggleH.png similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/icons/splitterToggleH.png rename to collabeditor/js/webodf/collab/dojox/layout/resources/icons/splitterToggleH.png diff --git a/api/js/webodf/collab/dojox/layout/resources/icons/splitterToggleV.png b/collabeditor/js/webodf/collab/dojox/layout/resources/icons/splitterToggleV.png similarity index 100% rename from api/js/webodf/collab/dojox/layout/resources/icons/splitterToggleV.png rename to collabeditor/js/webodf/collab/dojox/layout/resources/icons/splitterToggleV.png diff --git a/api/js/webodf/collab/dojox/widget/ColorPicker/ColorPicker.css b/collabeditor/js/webodf/collab/dojox/widget/ColorPicker/ColorPicker.css similarity index 100% rename from api/js/webodf/collab/dojox/widget/ColorPicker/ColorPicker.css rename to collabeditor/js/webodf/collab/dojox/widget/ColorPicker/ColorPicker.css diff --git a/api/js/webodf/collab/dojox/widget/ColorPicker/ColorPicker.html b/collabeditor/js/webodf/collab/dojox/widget/ColorPicker/ColorPicker.html similarity index 100% rename from api/js/webodf/collab/dojox/widget/ColorPicker/ColorPicker.html rename to collabeditor/js/webodf/collab/dojox/widget/ColorPicker/ColorPicker.html diff --git a/api/js/webodf/collab/dojox/widget/ColorPicker/images/hue.png b/collabeditor/js/webodf/collab/dojox/widget/ColorPicker/images/hue.png similarity index 100% rename from api/js/webodf/collab/dojox/widget/ColorPicker/images/hue.png rename to collabeditor/js/webodf/collab/dojox/widget/ColorPicker/images/hue.png diff --git a/api/js/webodf/collab/dojox/widget/ColorPicker/images/hueHandle.png b/collabeditor/js/webodf/collab/dojox/widget/ColorPicker/images/hueHandle.png similarity index 100% rename from api/js/webodf/collab/dojox/widget/ColorPicker/images/hueHandle.png rename to collabeditor/js/webodf/collab/dojox/widget/ColorPicker/images/hueHandle.png diff --git a/api/js/webodf/collab/dojox/widget/ColorPicker/images/hueHandleA11y.png b/collabeditor/js/webodf/collab/dojox/widget/ColorPicker/images/hueHandleA11y.png similarity index 100% rename from api/js/webodf/collab/dojox/widget/ColorPicker/images/hueHandleA11y.png rename to collabeditor/js/webodf/collab/dojox/widget/ColorPicker/images/hueHandleA11y.png diff --git a/api/js/webodf/collab/dojox/widget/ColorPicker/images/pickerPointer.png b/collabeditor/js/webodf/collab/dojox/widget/ColorPicker/images/pickerPointer.png similarity index 100% rename from api/js/webodf/collab/dojox/widget/ColorPicker/images/pickerPointer.png rename to collabeditor/js/webodf/collab/dojox/widget/ColorPicker/images/pickerPointer.png diff --git a/api/js/webodf/collab/dojox/widget/ColorPicker/images/underlay.png b/collabeditor/js/webodf/collab/dojox/widget/ColorPicker/images/underlay.png similarity index 100% rename from api/js/webodf/collab/dojox/widget/ColorPicker/images/underlay.png rename to collabeditor/js/webodf/collab/dojox/widget/ColorPicker/images/underlay.png diff --git a/api/js/webodf/collab/nbproject/project.properties b/collabeditor/js/webodf/collab/nbproject/project.properties similarity index 100% rename from api/js/webodf/collab/nbproject/project.properties rename to collabeditor/js/webodf/collab/nbproject/project.properties diff --git a/api/js/webodf/collab/resources/fonts/fonts.css b/collabeditor/js/webodf/collab/resources/fonts/fonts.css similarity index 100% rename from api/js/webodf/collab/resources/fonts/fonts.css rename to collabeditor/js/webodf/collab/resources/fonts/fonts.css diff --git a/api/js/webodf/collab/translations/de-DE.json b/collabeditor/js/webodf/collab/translations/de-DE.json similarity index 100% rename from api/js/webodf/collab/translations/de-DE.json rename to collabeditor/js/webodf/collab/translations/de-DE.json diff --git a/api/js/webodf/collab/translations/en-US.json b/collabeditor/js/webodf/collab/translations/en-US.json similarity index 100% rename from api/js/webodf/collab/translations/en-US.json rename to collabeditor/js/webodf/collab/translations/en-US.json diff --git a/api/js/webodf/collab/translations/eu.json b/collabeditor/js/webodf/collab/translations/eu.json similarity index 100% rename from api/js/webodf/collab/translations/eu.json rename to collabeditor/js/webodf/collab/translations/eu.json diff --git a/api/js/webodf/collab/translations/fr-FR.json b/collabeditor/js/webodf/collab/translations/fr-FR.json similarity index 100% rename from api/js/webodf/collab/translations/fr-FR.json rename to collabeditor/js/webodf/collab/translations/fr-FR.json diff --git a/api/js/webodf/collab/translations/it-IT.json b/collabeditor/js/webodf/collab/translations/it-IT.json similarity index 100% rename from api/js/webodf/collab/translations/it-IT.json rename to collabeditor/js/webodf/collab/translations/it-IT.json diff --git a/api/js/webodf/collab/translations/nl-NL.json b/collabeditor/js/webodf/collab/translations/nl-NL.json similarity index 100% rename from api/js/webodf/collab/translations/nl-NL.json rename to collabeditor/js/webodf/collab/translations/nl-NL.json diff --git a/api/js/webodf/collab/webodf.js b/collabeditor/js/webodf/collab/webodf.js similarity index 100% rename from api/js/webodf/collab/webodf.js rename to collabeditor/js/webodf/collab/webodf.js diff --git a/api/js/webodf/collab/welcome.odt b/collabeditor/js/webodf/collab/welcome.odt similarity index 100% rename from api/js/webodf/collab/welcome.odt rename to collabeditor/js/webodf/collab/welcome.odt diff --git a/api/js/webodf/collab/widgets/aboutDialog.js b/collabeditor/js/webodf/collab/widgets/aboutDialog.js similarity index 100% rename from api/js/webodf/collab/widgets/aboutDialog.js rename to collabeditor/js/webodf/collab/widgets/aboutDialog.js diff --git a/api/js/webodf/collab/widgets/annotation.js b/collabeditor/js/webodf/collab/widgets/annotation.js similarity index 100% rename from api/js/webodf/collab/widgets/annotation.js rename to collabeditor/js/webodf/collab/widgets/annotation.js diff --git a/api/js/webodf/collab/widgets/dialogWidgets/alignmentPane.html b/collabeditor/js/webodf/collab/widgets/dialogWidgets/alignmentPane.html similarity index 100% rename from api/js/webodf/collab/widgets/dialogWidgets/alignmentPane.html rename to collabeditor/js/webodf/collab/widgets/dialogWidgets/alignmentPane.html diff --git a/api/js/webodf/collab/widgets/dialogWidgets/alignmentPane.js b/collabeditor/js/webodf/collab/widgets/dialogWidgets/alignmentPane.js similarity index 100% rename from api/js/webodf/collab/widgets/dialogWidgets/alignmentPane.js rename to collabeditor/js/webodf/collab/widgets/dialogWidgets/alignmentPane.js diff --git a/api/js/webodf/collab/widgets/dialogWidgets/editHyperlinkPane.html b/collabeditor/js/webodf/collab/widgets/dialogWidgets/editHyperlinkPane.html similarity index 100% rename from api/js/webodf/collab/widgets/dialogWidgets/editHyperlinkPane.html rename to collabeditor/js/webodf/collab/widgets/dialogWidgets/editHyperlinkPane.html diff --git a/api/js/webodf/collab/widgets/dialogWidgets/editHyperlinkPane.js b/collabeditor/js/webodf/collab/widgets/dialogWidgets/editHyperlinkPane.js similarity index 100% rename from api/js/webodf/collab/widgets/dialogWidgets/editHyperlinkPane.js rename to collabeditor/js/webodf/collab/widgets/dialogWidgets/editHyperlinkPane.js diff --git a/api/js/webodf/collab/widgets/dialogWidgets/fontEffectsPane.html b/collabeditor/js/webodf/collab/widgets/dialogWidgets/fontEffectsPane.html similarity index 100% rename from api/js/webodf/collab/widgets/dialogWidgets/fontEffectsPane.html rename to collabeditor/js/webodf/collab/widgets/dialogWidgets/fontEffectsPane.html diff --git a/api/js/webodf/collab/widgets/dialogWidgets/fontEffectsPane.js b/collabeditor/js/webodf/collab/widgets/dialogWidgets/fontEffectsPane.js similarity index 100% rename from api/js/webodf/collab/widgets/dialogWidgets/fontEffectsPane.js rename to collabeditor/js/webodf/collab/widgets/dialogWidgets/fontEffectsPane.js diff --git a/api/js/webodf/collab/widgets/dialogWidgets/idMangler.js b/collabeditor/js/webodf/collab/widgets/dialogWidgets/idMangler.js similarity index 100% rename from api/js/webodf/collab/widgets/dialogWidgets/idMangler.js rename to collabeditor/js/webodf/collab/widgets/dialogWidgets/idMangler.js diff --git a/api/js/webodf/collab/widgets/editHyperlinks.js b/collabeditor/js/webodf/collab/widgets/editHyperlinks.js similarity index 100% rename from api/js/webodf/collab/widgets/editHyperlinks.js rename to collabeditor/js/webodf/collab/widgets/editHyperlinks.js diff --git a/api/js/webodf/collab/widgets/fontPicker.js b/collabeditor/js/webodf/collab/widgets/fontPicker.js similarity index 100% rename from api/js/webodf/collab/widgets/fontPicker.js rename to collabeditor/js/webodf/collab/widgets/fontPicker.js diff --git a/api/js/webodf/collab/widgets/imageInserter.js b/collabeditor/js/webodf/collab/widgets/imageInserter.js similarity index 100% rename from api/js/webodf/collab/widgets/imageInserter.js rename to collabeditor/js/webodf/collab/widgets/imageInserter.js diff --git a/api/js/webodf/collab/widgets/paragraphAlignment.js b/collabeditor/js/webodf/collab/widgets/paragraphAlignment.js similarity index 100% rename from api/js/webodf/collab/widgets/paragraphAlignment.js rename to collabeditor/js/webodf/collab/widgets/paragraphAlignment.js diff --git a/api/js/webodf/collab/widgets/paragraphStyles.js b/collabeditor/js/webodf/collab/widgets/paragraphStyles.js similarity index 100% rename from api/js/webodf/collab/widgets/paragraphStyles.js rename to collabeditor/js/webodf/collab/widgets/paragraphStyles.js diff --git a/api/js/webodf/collab/widgets/paragraphStylesDialog.js b/collabeditor/js/webodf/collab/widgets/paragraphStylesDialog.js similarity index 100% rename from api/js/webodf/collab/widgets/paragraphStylesDialog.js rename to collabeditor/js/webodf/collab/widgets/paragraphStylesDialog.js diff --git a/api/js/webodf/collab/widgets/simpleStyles.js b/collabeditor/js/webodf/collab/widgets/simpleStyles.js similarity index 100% rename from api/js/webodf/collab/widgets/simpleStyles.js rename to collabeditor/js/webodf/collab/widgets/simpleStyles.js diff --git a/api/js/webodf/collab/widgets/toolbarWidgets/currentStyle.js b/collabeditor/js/webodf/collab/widgets/toolbarWidgets/currentStyle.js similarity index 100% rename from api/js/webodf/collab/widgets/toolbarWidgets/currentStyle.js rename to collabeditor/js/webodf/collab/widgets/toolbarWidgets/currentStyle.js diff --git a/api/js/webodf/collab/widgets/undoRedoMenu.js b/collabeditor/js/webodf/collab/widgets/undoRedoMenu.js similarity index 100% rename from api/js/webodf/collab/widgets/undoRedoMenu.js rename to collabeditor/js/webodf/collab/widgets/undoRedoMenu.js diff --git a/api/js/webodf/collab/widgets/zoomSlider.js b/collabeditor/js/webodf/collab/widgets/zoomSlider.js similarity index 100% rename from api/js/webodf/collab/widgets/zoomSlider.js rename to collabeditor/js/webodf/collab/widgets/zoomSlider.js diff --git a/api/js/webodf/collab/wodocollabpane.css b/collabeditor/js/webodf/collab/wodocollabpane.css similarity index 100% rename from api/js/webodf/collab/wodocollabpane.css rename to collabeditor/js/webodf/collab/wodocollabpane.css diff --git a/api/js/webodf/collab/wodocollabtexteditor.js b/collabeditor/js/webodf/collab/wodocollabtexteditor.js similarity index 100% rename from api/js/webodf/collab/wodocollabtexteditor.js rename to collabeditor/js/webodf/collab/wodocollabtexteditor.js diff --git a/api/js/webodf/collab/wodotexteditor.css b/collabeditor/js/webodf/collab/wodotexteditor.css similarity index 100% rename from api/js/webodf/collab/wodotexteditor.css rename to collabeditor/js/webodf/collab/wodotexteditor.css diff --git a/api/js/webodf/collab/wodotexteditor.js b/collabeditor/js/webodf/collab/wodotexteditor.js similarity index 100% rename from api/js/webodf/collab/wodotexteditor.js rename to collabeditor/js/webodf/collab/wodotexteditor.js diff --git a/api/js/webodf/webodf-debug.js b/collabeditor/js/webodf/webodf-debug.js similarity index 100% rename from api/js/webodf/webodf-debug.js rename to collabeditor/js/webodf/webodf-debug.js diff --git a/api/js/webodf/webodf.js b/collabeditor/js/webodf/webodf.js similarity index 100% rename from api/js/webodf/webodf.js rename to collabeditor/js/webodf/webodf.js diff --git a/collabeditor/setup/setup.inc.php b/collabeditor/setup/setup.inc.php new file mode 100644 index 0000000000..2731ed1bcc --- /dev/null +++ b/collabeditor/setup/setup.inc.php @@ -0,0 +1,35 @@ + 'EGroupware GmbH', + 'url' => 'http://www.egroupware.org', +); +$setup_info['collabeditor']['license'] = 'GPL'; +$setup_info['collabeditor']['description'] = 'Online document editing with webodf editor'; + +/* The hooks this app includes, needed for hooks registration */ +$setup_info['collabeditor']['hooks']['filemanager-editor-link'] = 'EGroupware\collabeditor\Hooks::getEditorLink'; + +/* Dependencies for this app to work */ +$setup_info['collabeditor']['depends'][] = array( + 'appname' => 'filemanager', + 'versions' => array('17.1') +); +$setup_info['collabeditor']['depends'][] = array( + 'appname' => 'api', + 'versions' => array('17.1') +); \ No newline at end of file diff --git a/filemanager/inc/class.filemanager_collab.inc.php b/collabeditor/src/Bo.php similarity index 78% rename from filemanager/inc/class.filemanager_collab.inc.php rename to collabeditor/src/Bo.php index 7fbf731e89..0c0cea88ad 100644 --- a/filemanager/inc/class.filemanager_collab.inc.php +++ b/collabeditor/src/Bo.php @@ -1,27 +1,23 @@ - * @copyright (c) 2016 by Stylite AG + * @package collabeditor + * @author Hadi Nategh + * @copyright (c) 2016 by Hadi Nategh * @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License * @version $Id$ */ +namespace EGroupware\Collabeditor; use EGroupware\Api; +use EGroupware\Api\Vfs; -class filemanager_collab extends filemanager_collab_bo { - - /** - * Methods callable via menuaction - * - * @var array - */ - var $public_functions = array( - 'poll' => true - ); +/** + * Business Object of the Collabeditor + */ +class Bo extends So { /** * session identification for an empty new file @@ -38,7 +34,7 @@ class filemanager_collab extends filemanager_collab_bo { } /** - * Join session, initialises edit session for opened file by user + * Join session, initializes edit session for opened file by user * * @param type $es_id session id, 'new' session id means it's an empty * template opened as new file, and should not be store in DB. @@ -87,7 +83,7 @@ class filemanager_collab extends filemanager_collab_bo { } /** - * Polling mechanisim to sysncronise data + * Polling mechanism to synchronize data * * @throws Exception */ @@ -245,37 +241,73 @@ class filemanager_collab extends filemanager_collab_bo { } /** - * Ajax function to handle actions called by client-side - * types: save, delete, discard + * Save session for es_id * - * @param array $params - * @param string $action + * @param type $es_id + * @param type $file_path + * @return boolean returns true if successful, false in failure */ - function ajax_actions ($params, $action) + function save ($es_id, $file_path) { - $response = Api\Json\Response::get(); - switch ($action) - { - case 'save': - $this->SESSION_Save($params['es_id']); - //update genesis file after save happened - if ($params['file_path']) self::generateGenesis ($params['file_path'], $params['es_id']); - break; - case 'delete': - $this->SESSION_cleanup($params['es_id']); - break; - case 'discard': - $this->OP_Discard($params['es_id']); - break; - case 'checkLastMember': - $activeMembers = $this->MEMBER_getActiveMembers($params['es_id']); - $response->data(is_array($activeMembers) && count($activeMembers) > 1?false:true); - break; - default: - // + try{ + $this->SESSION_Save($es_id); + //update genesis file after save happened + if ($file_path) self::generateGenesis ($file_path, $es_id); + return true; + } catch (Exception $ex) { + error_log(__METHOD__.'()'.$ex->getMessage()); + return false; } } + /** + * delete an es_id from session + * @param type $es_id + * @return boolean returns true if successful, false in failure + */ + function delete ($es_id) + { + try{ + $this->SESSION_cleanup($es_id); + return true; + } catch (Exception $ex) { + error_log(__METHOD__.'()'.$ex->getMessage()); + return false; + } + } + + /** + * Discard changes to a session + * + * @param type $es_id + * @return boolean returns true if successful, false in failure + */ + function discard ($es_id) + { + try{ + $this->OP_Discard($es_id); + return true; + } catch (Exception $ex) { + error_log(__METHOD__.'()'.$ex->getMessage()); + return false; + } + } + + /** + * Check last active member in a session + * + * @param type $es_id + * @return array|boolean returns an array of active members, false in failure + */ + function checkLastMember ($es_id) + { + try{ + return $activeMembers = $this->MEMBER_getActiveMembers($es_id); + } catch (Exception $ex) { + error_log(__METHOD__.'()'.$ex->getMessage()); + return false; + } + } /** * Check if the collaboration is allowed for given file path @@ -288,8 +320,8 @@ class filemanager_collab extends filemanager_collab_bo { function is_collabAllowed ($file_path, $_right=null) { $paths = explode('/webdav.php', $file_path); - $right = $_right ? $_right : Api\Vfs::WRITABLE; - $allowed = Api\Vfs::check_access($paths[1], $right) && + $right = $_right ? $_right : Vfs::WRITABLE; + $allowed = Vfs::check_access($paths[1], $right) && !preg_match('/\/api\/js\/webodf\/template.odf$/', $file_path); return $allowed; } @@ -323,39 +355,43 @@ class filemanager_collab extends filemanager_collab_bo { /** * Function to get genesis url by generating a temp genesis temp file - * out of given path, and returnig es_id md5 hash and genesis url to + * out of given path, and returning es_id md5 hash and genesis url to * client. * * @param type $file_path file path * @param boolean $_isNew true means this is an empty doc opened as new file * in client-side and not stored yet therefore no genesis file should get generated for it. + * @return array returns array of data + * array( + * 'es_id', + * 'denesis_url' + * ) */ - function ajax_getGenesisUrl ($file_path, $_isNew) + function getGenesisUrl ($file_path, $_isNew) { $result = array(); $es_id = md5($file_path); - $response = Api\Json\Response::get(); + // handle new empty file if ($_isNew) { - $response->data(array ( + return array ( 'es_id' => self::NEW_FILE_ES_ID, 'genesis_url' => $GLOBALS['egw_info']['server']['webserver_url'].'/api/js/webodf/template.odt' - )); - return; + ); } $session = $this->SESSION_Get($es_id); if ($session && $session['genesis_url'] !== '') { $gen_file = explode('/webdav.php',$session['genesis_url']); - if (!Api\Vfs::file_exists($gen_file[1])) self::generateGenesis ($file_path, $es_id); + if (!Vfs::file_exists($gen_file[1])) self::generateGenesis ($file_path, $es_id); $result = array ( 'es_id' => $session['es_id'], 'genesis_url' => $session['genesis_url'] ); } - else if ($this->is_collabAllowed($file_path, Api\Vfs::WRITABLE)) + else if ($this->is_collabAllowed($file_path, Vfs::WRITABLE)) { $result = array ( 'es_id' => $es_id, @@ -363,7 +399,7 @@ class filemanager_collab extends filemanager_collab_bo { ); $this->SESSION_add2Db($es_id, $result['genesis_url']); } - $response->data($result); + return $result; } /** @@ -382,7 +418,7 @@ class filemanager_collab extends filemanager_collab_bo { $dir = join('/', $dir_parts); $genesis_file = $dir.'/.'.$es_id.'.webodf.odt'; $genesis_url = $paths[0].'/webdav.php'.$genesis_file; - Api\Vfs::copy($paths[1], $genesis_file); + Vfs::copy($paths[1], $genesis_file); return $genesis_url; } } \ No newline at end of file diff --git a/collabeditor/src/Hooks.php b/collabeditor/src/Hooks.php new file mode 100644 index 0000000000..146a180a10 --- /dev/null +++ b/collabeditor/src/Hooks.php @@ -0,0 +1,41 @@ + + * @copyright (c) 2016 by Hadi Nategh + * @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License + * @version $Id$ + */ +namespace EGroupware\Collabeditor; + +/** + * Description of Hooks + * + * @author hadi + */ +class Hooks { + + /** + * Gets links for open handler of collabeditor supported mime types + * + * @return array + */ + public static function getEditorLink() + { + return array ( + 'edit' => array( + 'menuaction' => 'collabeditor.EGroupware\\collabeditor\\Ui.editor', + ), + 'edit_popup' => '980x750', + 'mime' => array ( + 'application/vnd.oasis.opendocument.text' => array ( + 'mime_popup' => '' // try to avoid mime_open exception + ), + ) + ); + } +} diff --git a/filemanager/inc/class.filemanager_collab_bo.inc.php b/collabeditor/src/So.php similarity index 98% rename from filemanager/inc/class.filemanager_collab_bo.inc.php rename to collabeditor/src/So.php index cdb01817d1..f1bf79b225 100644 --- a/filemanager/inc/class.filemanager_collab_bo.inc.php +++ b/collabeditor/src/So.php @@ -1,21 +1,22 @@ - * @copyright (c) 2016 by Stylite AG + * @package collabeditor + * @author Hadi Nategh + * @copyright (c) 2016 by Hadi Nategh * @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License * @version $Id$ */ +namespace EGroupware\Collabeditor; use EGroupware\Api; /** - * Storage Object of the filemanager + * Storage Object of the Collabeditor */ -class filemanager_collab_bo +class So { /** @@ -553,7 +554,7 @@ class filemanager_collab_bo */ static function getTimeStamp () { - $date = new DateTime(); + $date = new Api\DateTime(); return $date->getTimestamp(); } } \ No newline at end of file diff --git a/collabeditor/src/Ui.php b/collabeditor/src/Ui.php new file mode 100644 index 0000000000..ca8be16b76 --- /dev/null +++ b/collabeditor/src/Ui.php @@ -0,0 +1,206 @@ + + * @copyright (c) 2016 by Hadi Nategh + * @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License + * @version $Id$ + */ +namespace EGroupware\Collabeditor; + +use EGroupware\Api; +use EGroupware\Api\Vfs; +use EGroupware\Api\Json; +use EGroupware\Api\Etemplate; + +class Ui { + + /** + * Methods callable via menuaction + * + * @var array + */ + var $public_functions = array( + 'editor' => true, + 'poll' => true + ); + + /** + * Constructor + * + */ + function __construct() + { + $this->bo = new Bo(); + } + + /** + * Editor for odf files + * + * @param array $content + */ + function editor($content=null) + { + $tmpl = new Etemplate('collabeditor.editor'); + $path = $_GET['path']; + if (!preg_match("/\/webdav.php\//", $path)) + { + $download_url = Vfs::download_url($path); + } + else + { + $download_url = $path; + $paths = explode('/webdav.php', $path); + $path = $paths[1]; + } + + // Include css files used by wodocollabeditor + Api\Framework::includeCSS('/collabeditor/js/webodf/collab/app/resources/app.css'); + Api\Framework::includeCSS('/collabeditor/js/webodf/collab/wodocollabpane.css'); + Api\Framework::includeCSS('/collabeditor/js/webodf/collab/wodotexteditor.css'); + Api\Framework::includeJS('/collabeditor/js/app.js',null, 'collabeditor'); + + if (!$content) + { + if ($download_url) + { + $content['es_id'] = md5 ($download_url); + $content['file_path'] = $path; + } + else + { + $content = array(); + } + } + + $actions = self::getActions(); + if (!Vfs::check_access($path, Vfs::WRITABLE)) + { + unset ($actions['save']); + unset ($actions['discard']); + unset ($actions['delete']); + } + $tmpl->setElementAttribute('tools', 'actions', $actions); + $preserve = $content; + $tmpl->exec('collabeditor.'.__CLASS__.'.editor',$content,array(),array(),$preserve,2); + } + + /** + * Polling mechanism to synchronize data + * + * @throws Exception + */ + function poll () + { + $this->bo->poll(); + } + + /** + * Ajax function to handle actions called by client-side + * types: save, delete, discard + * + * @param array $params + * @param string $action + */ + function ajax_actions ($params, $action) + { + $response = Json\Response::get(); + switch ($action) + { + case 'save': + $this->bo->save($params['es_id'], $params['file_path']); + break; + case 'delete': + $this->bo->delete($params['es_id']); + break; + case 'discard': + $this->bo->discard($params['es_id']); + break; + case 'checkLastMember': + $activeMembers = $this->bo->checkLastMember($params['es_id']); + $response->data(is_array($activeMembers) && count($activeMembers) > 1?false:true); + break; + default: + // + } + } + + /** + * Function to get genesis url by generating a temp genesis temp file + * out of given path, and returning es_id md5 hash and genesis url to + * client. + * + * @param type $file_path file path + * @param boolean $_isNew true means this is an empty doc opened as new file + * in client-side and not stored yet therefore no genesis file should get generated for it. + */ + function ajax_getGenesisUrl ($file_path, $_isNew) + { + $response = Json\Response::get(); + $response->data($this->bo->getGenesisUrl($file_path, $_isNew)); + } + + /** + * Editor dialog's toolbar actions + * + * @return array return array of actions + */ + static function getActions() + { + $group = 0; + $actions = array ( + 'save' => array( + 'caption' => 'Save', + 'icon' => 'apply', + 'group' => ++$group, + 'onExecute' => 'javaScript:app.filemanager.editor_save', + 'allowOnMultiple' => false, + 'toolbarDefault' => true + ), + 'new' => array( + 'caption' => 'New', + 'icon' => 'add', + 'group' => ++$group, + 'onExecute' => 'javaScript:app.filemanager.create_new', + 'allowOnMultiple' => false, + 'toolbarDefault' => true + ), + 'close' => array( + 'caption' => 'Close', + 'icon' => 'close', + 'group' => ++$group, + 'onExecute' => 'javaScript:app.filemanager.editor_close', + 'allowOnMultiple' => false, + 'toolbarDefault' => true + ), + 'saveas' => array( + 'caption' => 'Save As', + 'icon' => 'save_all', + 'group' => ++$group, + 'onExecute' => 'javaScript:app.filemanager.editor_save', + 'allowOnMultiple' => false, + 'toolbarDefault' => true + ), + 'delete' => array( + 'caption' => 'Delete', + 'icon' => 'delete', + 'group' => ++$group, + 'onExecute' => 'javaScript:app.filemanager.editor_delete', + 'allowOnMultiple' => false, + 'toolbarDefault' => false + ), + 'discard' => array( + 'caption' => 'Discard', + 'icon' => 'discard', + 'group' => ++$group, + 'onExecute' => 'javaScript:app.filemanager.editor_discard', + 'allowOnMultiple' => false, + 'toolbarDefault' => false + ) + ); + return $actions; + } +} \ No newline at end of file diff --git a/collabeditor/templates/default/app.css b/collabeditor/templates/default/app.css new file mode 100644 index 0000000000..20541c5419 --- /dev/null +++ b/collabeditor/templates/default/app.css @@ -0,0 +1,66 @@ +/** + * EGroupware - CSS Styles used by collabeditor app + * + * @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License + * @package etemplate + * @link http://www.egroupware.org + * @author Hadi Nategh + * @version $Id$ + */ + + +#collabeditor-editor_file_path { + font-size: 11pt; + display: inline-block; + margin-top: 5px; + margin-left: 10px; +} + +#collabeditor-editor_odfEditor { + position: absolute; + height: ~"calc(100% - 50px) !important"; + width:100% !important; + top:50px; + left: 0px; + bottom: 0px; + right:0px; + padding:0px !important; +} +#collabeditor-editor_odfEditor .webodfeditor-editor.dijitContentPane { + box-shadow: none; + left:0px !important; + top: 0px !important; +} +#collabeditor-editor { + overflow: hidden; +} + +/* collab editor styling*/ +div.webodfeditor-members { + background-color: white !important; + +} +div.webodfeditor-memberList .webodfeditor-memberListButton { + border: none !important; + background-color: transparent !important; + box-shadow: none !important; + +} +div.webodfeditor-memberList .webodfeditor-memberListButton img { + border-radius: 50%; + box-shadow: none; +} +div.webodfeditor-memberList .webodfeditor-memberListLabel { + color: #1E1E1E; +} +div.webodf-caretOverlay div.handle { + width:68px; + border-radius:50%; +} +div.webodf-caretOverlay div.handle>img{ + border-radius: 50%; +} +div.editInfoMarker { + width:5px; + border-radius: none; +} diff --git a/collabeditor/templates/default/editor.xet b/collabeditor/templates/default/editor.xet new file mode 100644 index 0000000000..19e7a7818d --- /dev/null +++ b/collabeditor/templates/default/editor.xet @@ -0,0 +1,32 @@ + + + + + + diff --git a/filemanager/inc/class.filemanager_ui.inc.php b/filemanager/inc/class.filemanager_ui.inc.php index daa9ab839b..2de6ce76b7 100644 --- a/filemanager/inc/class.filemanager_ui.inc.php +++ b/filemanager/inc/class.filemanager_ui.inc.php @@ -1604,115 +1604,4 @@ class filemanager_ui } return $mode; } - - /** - * Editor for odf files - * - * @param array $content - */ - function editor($content=null) - { - $tmpl = new Etemplate('filemanager.editor'); - $path = $_GET['path']; - if (!preg_match("/\/webdav.php\//", $path)) - { - $download_url = Vfs::download_url($path); - } - else - { - $download_url = $path; - $paths = explode('/webdav.php', $path); - $path = $paths[1]; - } - // Include css files used by wodocollabeditor - Api\Framework::includeCSS('/api/js/webodf/collab/app/resources/app.css'); - Api\Framework::includeCSS('/api/js/webodf/collab/wodocollabpane.css'); - Api\Framework::includeCSS('/api/js/webodf/collab/wodotexteditor.css'); - Api\Framework::includeJS('/filemanager/js/collab.js',null, 'filemanager'); - - if (!$content) - { - if ($download_url) - { - $content['es_id'] = md5 ($download_url); - $content['file_path'] = $path; - } - else - { - $content = array(); - } - } - - $actions = self::getActions_edit(); - if (!Api\Vfs::check_access($path, Api\Vfs::WRITABLE)) - { - unset ($actions['save']); - unset ($actions['discard']); - unset ($actions['delete']); - } - $tmpl->setElementAttribute('tools', 'actions', $actions); - $preserve = $content; - $tmpl->exec('filemanager.filemanager_ui.editor',$content,array(),array(),$preserve,2); - } - - /** - * Editor dialog's toolbar actions - * - * @return array return array of actions - */ - static function getActions_edit() - { - $group = 0; - $actions = array ( - 'save' => array( - 'caption' => 'Save', - 'icon' => 'apply', - 'group' => ++$group, - 'onExecute' => 'javaScript:app.filemanager.editor_save', - 'allowOnMultiple' => false, - 'toolbarDefault' => true - ), - 'new' => array( - 'caption' => 'New', - 'icon' => 'add', - 'group' => ++$group, - 'onExecute' => 'javaScript:app.filemanager.create_new', - 'allowOnMultiple' => false, - 'toolbarDefault' => true - ), - 'close' => array( - 'caption' => 'Close', - 'icon' => 'close', - 'group' => ++$group, - 'onExecute' => 'javaScript:app.filemanager.editor_close', - 'allowOnMultiple' => false, - 'toolbarDefault' => true - ), - 'saveas' => array( - 'caption' => 'Save As', - 'icon' => 'save_all', - 'group' => ++$group, - 'onExecute' => 'javaScript:app.filemanager.editor_save', - 'allowOnMultiple' => false, - 'toolbarDefault' => true - ), - 'delete' => array( - 'caption' => 'Delete', - 'icon' => 'delete', - 'group' => ++$group, - 'onExecute' => 'javaScript:app.filemanager.editor_delete', - 'allowOnMultiple' => false, - 'toolbarDefault' => false - ), - 'discard' => array( - 'caption' => 'Discard', - 'icon' => 'discard', - 'group' => ++$group, - 'onExecute' => 'javaScript:app.filemanager.editor_discard', - 'allowOnMultiple' => false, - 'toolbarDefault' => false - ) - ); - return $actions; - } } diff --git a/filemanager/js/app.js b/filemanager/js/app.js index a9a3ec9b9e..09bc4e6fdc 100644 --- a/filemanager/js/app.js +++ b/filemanager/js/app.js @@ -780,10 +780,11 @@ app.classes.filemanager = AppJS.extend( } else if (mime && this.isEditable(_action, _senders)) { + var fe = egw.link_get_registry('filemanager-editor'); egw.open_link(egw.link('/index.php', { - menuaction: 'filemanager.filemanager_ui.editor', + menuaction: fe.edit.menuaction, path: decodeURIComponent(data.data.download_url) - }), '', egw.link_get_registry('filemanager','view_popup')); + }), '', fe.edit_popup); } else {