parro-it / electron-localshortcut

Add keyboard shortcuts locally to a BrowserWindow instance, without using a Menu
MIT License
422 stars 38 forks source link

On qwertz keyboard, "z" and "y" are triggered by both "z" and "y" #106

Open jawidde opened 2 years ago

jawidde commented 2 years ago

If I define register for Ctrl + Z or Ctrl + Y for undo and redo, only the one defined first is executed, regardless of whether Ctrl + Z or Ctrl + Y is typed on keyboard. I use a qwertz keyboard for input.

  electronLocalshortcut.register(win, 'Ctrl+Z', () => {
    ... [executed if Ctrl + Z or Ctrl + Y is pressed]
  });
  electronLocalshortcut.register(win, 'Ctrl+Y', () => {
    ... [never executed]
  });