Per https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key and https://caniuse.com/#feat=keyboardevent-key it is available in Safari.
Being said that pls use gwt-user group for getting support. On Wed, Jul 26, 2017 at 4:44 PM, Harsh Yadav <[email protected]> wrote: > The following code breaks in Safari, as KeyboardEvent.key is not supported > in Safari (https://www.w3schools.com/jsref/event_key_key.asp): > > inputElement.addEventListener("keypress", inKeyPressEvent -> { > > if (!"Enter".equals(((KeyboardEvent) inKeyPressEvent).key)) { > > handleKeyPress(); > } > }); > > > The possible alternatives like: > charCode, keyCode <https://www.w3schools.com/jsref/event_key_keycode.asp>, > which <https://www.w3schools.com/jsref/event_key_which.asp> > could be used in this case, however they are not exposed via the > KeyboardEvent class inside Elemental2 > Is there a work-around (other than JSNI as it works correctly)? > > Thanks, > Harsh > > -- > You received this message because you are subscribed to the Google Groups > "GWT Contributors" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit https://groups.google.com/d/ > msgid/google-web-toolkit-contributors/da14cf45-97b8- > 43bd-b826-c34d6101b07f%40googlegroups.com > <https://groups.google.com/d/msgid/google-web-toolkit-contributors/da14cf45-97b8-43bd-b826-c34d6101b07f%40googlegroups.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "GWT Contributors" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit-contributors/CAN%3DyUA38opNgJCiZ2WB95nMzsgz416bnoyRa1hAoD%2B97O1q--g%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
