Converting key names to lower case now.

This commit is contained in:
Marat Fayzullin 2024-08-20 12:16:26 -04:00
parent 13f56369bb
commit e3c738385a
1 changed files with 5 additions and 5 deletions

View File

@ -150,8 +150,8 @@ Shortcuts.handleKey = function(event) {
// Leave CTRL+<LETTER> combinations to the browser
if (event.ctrlKey && event.key.match(/^[a-z]$/i)) return;
switch (event.key) {
case 'ArrowLeft':
switch (event.key.toLowerCase()) {
case 'arrowleft':
if (event.ctrlKey) {
// CTRL+LEFT: Decrease squelch
this.moveSlider('#openwebrx-panel-receiver .openwebrx-squelch-slider', -1);
@ -170,7 +170,7 @@ Shortcuts.handleKey = function(event) {
}
break;
case 'ArrowRight':
case 'arrowright':
if (event.ctrlKey) {
// CTRL+RIGHT: Increase squelch
this.moveSlider('#openwebrx-panel-receiver .openwebrx-squelch-slider', 1);
@ -189,7 +189,7 @@ Shortcuts.handleKey = function(event) {
}
break;
case 'ArrowUp':
case 'arrowup':
if (event.ctrlKey) {
// CTRL+UP: Increase volume
this.moveSlider('#openwebrx-panel-volume', 1);
@ -208,7 +208,7 @@ Shortcuts.handleKey = function(event) {
}
break;
case 'ArrowDown':
case 'arrowdown':
if (event.ctrlKey) {
// CTRL+DOWN: Decrease volume
this.moveSlider('#openwebrx-panel-volume', -1);