summaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
Diffstat (limited to 'apps')
-rw-r--r--apps/files/js/newfilemenu.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/apps/files/js/newfilemenu.js b/apps/files/js/newfilemenu.js
index 3581b2cd8fc..0ad7312c985 100644
--- a/apps/files/js/newfilemenu.js
+++ b/apps/files/js/newfilemenu.js
@@ -237,8 +237,10 @@
OC.Util.scaleFixForIE8(this.$('.svg'));
// Trigger upload action also with keyboard navigation on enter
- this.$el.find('[for="file_upload_start"]').on('keypress', function() {
- $('#file_upload_start').trigger('click');
+ this.$el.find('[for="file_upload_start"]').on('keyup', function(event) {
+ if (event.key === " " || event.key === "Enter") {
+ $('#file_upload_start').trigger('click');
+ }
});
},