diff options
author | Julius Härtl <jus@bitgrid.net> | 2019-03-07 17:24:40 +0300 |
---|---|---|
committer | Julius Härtl <jus@bitgrid.net> | 2019-03-07 17:24:40 +0300 |
commit | 544f62a5bf241a72c677991916bc3a0449ae9a98 (patch) | |
tree | cf892a7e189a86befb0e9c5441ef2b2a4c48c4e5 /js/documents.js | |
parent | 25554b7a763ee792d9de90817c595ef3dc01d02a (diff) |
Fix translations for file actions
Signed-off-by: Julius Härtl <jus@bitgrid.net>
Diffstat (limited to 'js/documents.js')
-rw-r--r-- | js/documents.js | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/js/documents.js b/js/documents.js index 8e66b90f..34274ef1 100644 --- a/js/documents.js +++ b/js/documents.js @@ -242,21 +242,23 @@ var documentsMain = { parent.OCA.Files.App.fileList.fileActions.actions.all.Favorite.action(documentsMain.fileName, context) }); if (isFavorite(context.fileInfoModel)) { - $favorite.find('a').text(t('files', 'Remove from favorites')); + $favorite.find('a').text(parent.t('files', 'Remove from favorites')); $favorite.find('a').addClass('icon-starred'); } else { - $favorite.find('a').text(t('files', 'Add to favorites')); + $favorite.find('a').text(parent.t('files', 'Add to favorites')); $favorite.find('a').addClass('icon-star-dark'); } - var $info = $('<li><a class="icon-info">Details</a></li>').click(function() { - parent.OCA.Files.App.fileList.fileActions.actions.all.Details.action(documentsMain.fileName, context) + var $info = $('<li><a class="icon-info"></a></li>').click(function() { + documentsMain.getFileList().fileActions.actions.all.Details.action(documentsMain.fileName, context) parent.OC.hideMenus(); }); + $info.find('a').text(parent.t('files', 'Details')); var $download = $('<li><a class="icon-download">Download</a></li>').click(function() { - parent.OCA.Files.App.fileList.fileActions.actions.all.Download.action(documentsMain.fileName, context) + documentsMain.getFileList().fileActions.actions.all.Download.action(documentsMain.fileName, context) parent.OC.hideMenus(); }); + $download.find('a').text(parent.t('files', 'Download')); actions.append($favorite).append($info).append($download); actionsContainer.insertAfter(parent.$('#header .richdocuments-sharing')); parent.OC.registerMenu(parent.$('#richdocuments-actions .icon-more'), parent.$('#richdocuments-actions-menu'), false, true); |