My application is currently using add_acceleratorkeypressed to intercept keypresses in the host. The aim was to prevent or remap keys like ctrl-p and prevent default dialogs. The problem is, it seems that those keypresses aren't getting raised as JS events, EG: window.addEventListener('keydown', console.log) will print nothing. If I return false for handled, then the print dialog will be opened, but if i return true, the event isn't raised in JS.
What's the correct approach to this problem? Thanks.
My application is currently using add_acceleratorkeypressed to intercept keypresses in the host. The aim was to prevent or remap keys like
ctrl-pand prevent default dialogs. The problem is, it seems that those keypresses aren't getting raised as JS events, EG:window.addEventListener('keydown', console.log)will print nothing. If I returnfalsefor handled, then the print dialog will be opened, but if i return true, the event isn't raised in JS.What's the correct approach to this problem? Thanks.