diff options
author | Vincent Petry <pvince81@owncloud.com> | 2016-01-27 18:28:55 +0100 |
---|---|---|
committer | Vincent Petry <pvince81@owncloud.com> | 2016-02-02 18:01:15 +0100 |
commit | cca33942aa01542c7b9920c80c66e3becd3a0d9c (patch) | |
tree | b1eea7483ea67a445815e579032dedfa23b2d3c5 /apps/comments/js/filesplugin.js | |
parent | 0e95b9f2d560f5fc177e672162e995341cfba025 (diff) | |
download | nextcloud-server-cca33942aa01542c7b9920c80c66e3becd3a0d9c.tar.gz nextcloud-server-cca33942aa01542c7b9920c80c66e3becd3a0d9c.zip |
Comments GUI
Diffstat (limited to 'apps/comments/js/filesplugin.js')
-rw-r--r-- | apps/comments/js/filesplugin.js | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/apps/comments/js/filesplugin.js b/apps/comments/js/filesplugin.js new file mode 100644 index 00000000000..c8d91e0ede3 --- /dev/null +++ b/apps/comments/js/filesplugin.js @@ -0,0 +1,41 @@ +/* + * Copyright (c) 2016 Vincent Petry <pvince81@owncloud.com> + * + * This file is licensed under the Affero General Public License version 3 + * or later. + * + * See the COPYING-README file. + * + */ + +(function() { + OCA.Comments = _.extend({}, OCA.Comments); + if (!OCA.Comments) { + /** + * @namespace + */ + OCA.Comments = {}; + } + + /** + * @namespace + */ + OCA.Comments.FilesPlugin = { + allowedLists: [ + 'files', + 'favorites' + ], + + attach: function(fileList) { + if (this.allowedLists.indexOf(fileList.id) < 0) { + return; + } + + fileList.registerTabView(new OCA.Comments.CommentsTabView('commentsTabView')); + } + }; + +})(); + +OC.Plugins.register('OCA.Files.FileList', OCA.Comments.FilesPlugin); + |