aboutsummaryrefslogtreecommitdiffstats
path: root/src/js
diff options
context:
space:
mode:
Diffstat (limited to 'src/js')
-rw-r--r--src/js/listeners.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/js/listeners.js b/src/js/listeners.js
index 29038a21..9483c6a9 100644
--- a/src/js/listeners.js
+++ b/src/js/listeners.js
@@ -325,10 +325,10 @@ const listeners = {
};
// Keyboard shortcuts
- if (this.config.keyboard.focused) {
- utils.on(this.elements.container, 'keydown keyup', handleKey, false);
- } else if (this.config.keyboard.global) {
+ if (this.config.keyboard.global) {
utils.on(window, 'keydown keyup', handleKey, false);
+ } else if (this.config.keyboard.focused) {
+ utils.on(this.elements.container, 'keydown keyup', handleKey, false);
}
// Detect tab focus