summaryrefslogtreecommitdiff
path: root/ext/bg/js/search.js
diff options
context:
space:
mode:
Diffstat (limited to 'ext/bg/js/search.js')
-rw-r--r--ext/bg/js/search.js16
1 files changed, 10 insertions, 6 deletions
diff --git a/ext/bg/js/search.js b/ext/bg/js/search.js
index 1a6822f6..6481e16a 100644
--- a/ext/bg/js/search.js
+++ b/ext/bg/js/search.js
@@ -104,17 +104,21 @@ class DisplaySearch extends Display {
let activeModifierMap = {
'Control': e.ctrlKey,
- 'Meta': e.metaKey
+ 'Meta': e.metaKey,
+ 'ANY_MOD': true
};
- // true if no known modifier is pressed
- activeModifierMap[undefined] = !Object.values(activeModifierMap).includes(true);
const ignoreKeys = {
- undefined: ['Tab'],
- 'Control': ['C', 'A', 'Z', 'Y', 'X', 'F'],
- 'Meta': ['C', 'A', 'Z', 'Y', 'X', 'F'],
+ 'ANY_MOD': ['Tab', 'ArrowUp', 'ArrowDown', 'ArrowLeft', 'ArrowRight', 'PageDown', 'PageUp', 'Home', 'End']
+ .concat(
+ Array.from(Array(24).keys())
+ .map(i => `F${i + 1}`)
+ ),
+ 'Control': ['C', 'A', 'Z', 'Y', 'X', 'F', 'G'],
+ 'Meta': ['C', 'A', 'Z', 'Y', 'X', 'F', 'G'],
'OS': [],
'Alt': [],
+ 'AltGraph': [],
'Shift': []
}