summaryrefslogtreecommitdiffstats
path: root/apps/files_versions
diff options
context:
space:
mode:
authorVincent Petry <pvince81@owncloud.com>2014-05-20 16:01:34 +0200
committerVincent Petry <pvince81@owncloud.com>2014-05-30 10:06:29 +0200
commitef59c69dc822c9ff69c564c41e0dfdce142b9cdf (patch)
treea99667ab22daba65cbbd77ac591fccac234f06eb /apps/files_versions
parentfa32243d84e1801c379a5e8956ba2f3de236c718 (diff)
downloadnextcloud-server-ef59c69dc822c9ff69c564c41e0dfdce142b9cdf.tar.gz
nextcloud-server-ef59c69dc822c9ff69c564c41e0dfdce142b9cdf.zip
Distinguish legacy file actions from regular file actions
Legacy file actions are registered by legacy apps through window.FileActions.register(). These actions can only be used by the main file list ("all files") because legacy apps can only deal with a single list / container. New file actions of compatible apps must be registered through OCA.Files.fileActions. These will be used for other lists like the sharing overview. Fixed versions and sharing actions to use OCA.Files.fileActions, which makes them available in the sharing overview list.
Diffstat (limited to 'apps/files_versions')
-rw-r--r--apps/files_versions/js/versions.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/apps/files_versions/js/versions.js b/apps/files_versions/js/versions.js
index a23935495d7..942a1a929f7 100644
--- a/apps/files_versions/js/versions.js
+++ b/apps/files_versions/js/versions.js
@@ -8,7 +8,7 @@
*
*/
-/* global FileActions, scanFiles, escapeHTML, formatDate */
+/* global scanFiles, escapeHTML, formatDate */
$(document).ready(function(){
if ($('#isPublic').val()){
@@ -18,9 +18,9 @@ $(document).ready(function(){
return;
}
- if (typeof FileActions !== 'undefined') {
+ if (OCA.Files) {
// Add versions button to 'files/index.php'
- FileActions.register(
+ OCA.Files.fileActions.register(
'file',
'Versions',
OC.PERMISSION_UPDATE,