Vaadin lets you build secure, UX-first PWAs entirely in Java.
Free ebook & tutorial.
How to ignore ESC-key default behavior?
I noticed one problem when I accidentally hit ESC-key while there was progress indicator running because of a time consuming process being executed. ESC-key interrupted the process and after that I got some communication exceptions. I noticed that ESC-key doesn't have any effect in Opera but in iExplorer and Firefox the problem occurs. Is there some way to ignore ESC-key in my Vaadin-app or should I try to register action for ESC-key so that my processing thread is interrupted gently?
Since this is a known problem that hitting ESC will cancel active XHR-request in Firefox and IE and there isn't a way to prevent this from happening in any reasonable way in my Vaadin app, I've come up with a workaround that seems to be working fairly well. I've created my own Window-class which is registering the ESC-key shortcut to do nothing and extend this custom window everywhere in my app. I know this is ugly but I had to do something and couldn't find any reasonable solution to this.