summaryrefslogtreecommitdiffstats
path: root/core/js/js.js
diff options
context:
space:
mode:
authorKevin Ndung'u <kevgathuku@gmail.com>2018-07-23 11:17:32 +0300
committerDaniel Calviño Sánchez <danxuliu@gmail.com>2018-07-24 19:02:56 +0200
commitfe2509231213409238c8243c8211bcab0bc4a00b (patch)
treecfd3da5d87a0351d3126879be97fd3c70c7f3f79 /core/js/js.js
parent1cdf808197156b5389444db298f78c5255dd165c (diff)
downloadnextcloud-server-fe2509231213409238c8243c8211bcab0bc4a00b.tar.gz
nextcloud-server-fe2509231213409238c8243c8211bcab0bc4a00b.zip
Remove deprecated keyboard events & properties
Signed-off-by: Kevin Ndung'u <kevgathuku@gmail.com>
Diffstat (limited to 'core/js/js.js')
-rw-r--r--core/js/js.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/core/js/js.js b/core/js/js.js
index 015517020b4..5b5ff6bf3f1 100644
--- a/core/js/js.js
+++ b/core/js/js.js
@@ -684,12 +684,12 @@ var OCP = {},
registerMenu: function($toggle, $menuEl, toggle, headerMenu) {
var self = this;
$menuEl.addClass('menu');
- $toggle.on('click.menu keypress.menu', function(event) {
+ $toggle.on('click.menu keyup.menu', function(event) {
// prevent the link event (append anchor to URL)
event.preventDefault();
// allow enter key as a trigger
- if (event.keyCode && event.keyCode !== 13) {
+ if (event.key && event.key !== "Enter") {
return;
}
@@ -1431,7 +1431,7 @@ function initCore() {
$(document).on('mouseup.closemenus', function(event) {
// allow enter as a trigger
- // if (event.keyCode && event.keyCode !== 13) {
+ // if (event.key && event.key !== "Enter") {
// return;
// }