mirror of
https://github.com/Fabio286/antares.git
synced 2025-03-12 09:20:06 +01:00
fix(Linux): remove app menu shown pressing ALT key
This commit is contained in:
parent
9ef475ec3f
commit
63fece2a1b
@ -75,7 +75,7 @@ export class ShortcutRegister {
|
|||||||
for (const key of shortcut.keys) {
|
for (const key of shortcut.keys) {
|
||||||
try {
|
try {
|
||||||
this._menu.append(new MenuItem({
|
this._menu.append(new MenuItem({
|
||||||
label: 'Shortcuts',
|
label: '.',
|
||||||
visible: false,
|
visible: false,
|
||||||
submenu: [{
|
submenu: [{
|
||||||
label: String(key),
|
label: String(key),
|
||||||
|
@ -52,7 +52,6 @@ async function createMainWindow () {
|
|||||||
trafficLightPosition: isMacOS ? { x: 10, y: 8 } : undefined,
|
trafficLightPosition: isMacOS ? { x: 10, y: 8 } : undefined,
|
||||||
backgroundColor: '#1d1d1d'
|
backgroundColor: '#1d1d1d'
|
||||||
});
|
});
|
||||||
window.removeMenu();
|
|
||||||
|
|
||||||
mainWindowState.manage(window);
|
mainWindowState.manage(window);
|
||||||
window.on('moved', saveWindowState);
|
window.on('moved', saveWindowState);
|
||||||
|
@ -130,6 +130,12 @@ onMounted(() => {
|
|||||||
node = node.parentNode;
|
node = node.parentNode;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
document.addEventListener('keydown', e => {
|
||||||
|
if (e.altKey && e.key === 'Alt') { // Prevent Alt key to trigger hidden shortcut menu
|
||||||
|
e.preventDefault();
|
||||||
|
}
|
||||||
|
});
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user