diff options
author | Jörn Friedrich Dreyer <jfd@butonic.de> | 2013-08-08 13:50:04 +0200 |
---|---|---|
committer | Jörn Friedrich Dreyer <jfd@butonic.de> | 2013-08-08 13:50:04 +0200 |
commit | ff67f115d403d13dedf77457c539963f50a80eec (patch) | |
tree | 1b406eb56e1355b672c4d6f8a6d962e6042a64d7 /apps/files/js/fileactions.js | |
parent | 057d7aa108f9b24c12b97f5f78008eb17a6d3bee (diff) | |
download | nextcloud-server-ff67f115d403d13dedf77457c539963f50a80eec.tar.gz nextcloud-server-ff67f115d403d13dedf77457c539963f50a80eec.zip |
fix #2711 using a custom event, also use css selectors over filterAttr
Diffstat (limited to 'apps/files/js/fileactions.js')
-rw-r--r-- | apps/files/js/fileactions.js | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/apps/files/js/fileactions.js b/apps/files/js/fileactions.js index aa66a57a7b5..de67d13559e 100644 --- a/apps/files/js/fileactions.js +++ b/apps/files/js/fileactions.js @@ -65,7 +65,7 @@ var FileActions = { FileActions.currentFile = parent; var actions = FileActions.get(FileActions.getCurrentMimeType(), FileActions.getCurrentType(), FileActions.getCurrentPermissions()); var file = FileActions.getCurrentFile(); - if ($('tr').filterAttr('data-file', file).data('renaming')) { + if ($('tr[data-file="'+file+'"]').data('renaming')) { return; } parent.children('a.name').append('<span class="fileactions" />'); @@ -164,10 +164,11 @@ $(document).ready(function () { window.location = OC.filePath('files', 'ajax', 'download.php') + '?files=' + encodeURIComponent(filename) + '&dir=' + encodeURIComponent($('#dir').val()); }); } - $('#fileList tr').each(function () { FileActions.display($(this).children('td.filename')); }); + + $('#fileList').trigger(jQuery.Event("fileActionsReady")); }); |