recursiveElk 24 Report post Posted November 9, 2017 Demo When running program locally in the IDE's browser the keycode for enter is 13 as expected. When running program on chrome, mozilla or other browsers keycode = 69. 1 IElite reacted to this Share this post Link to post Share on other sites
IElite 263 Report post Posted November 9, 2017 Yup, that is what I am getting too! 1 Czar reacted to this Share this post Link to post Share on other sites
jarto 428 Report post Posted November 11, 2017 This is, what I wrote on the Smart Mobile Studio Facebook page a while ago: Quote Some people are just way too pedantic. While testing I noticed that my Android phone did not trigger OnKeyPress. While investigating I found a lot of Google hits on the same problem. As people can speak to input text or write multi-char smileys, someone thought that it's a great idea to deprecate an event, that has been used ever since computers had more than 1 MB of memory. There were a lot of suggestions on how to work around this. Many suggest to use OnInput (which will be introduced in the next update, along this fix), but basically only one browser included the pressed key in the event. Some suggested to store the text at OnKeyDown and to compare the contents at OnKeyUp. Long story short: In the future we'll listen to both OnKeyPress and OnInput. If OnKeyPress was not triggered or the key was not found, we try to find the key during OnInput. If we do find it, we simulate a OnKeyPress. Oh, and OnKeyPress contains the changed key. But what happens when you write a smiley on mobile? The whole smiley is sent even though it's longer than one character. If someone thinks that's a problem, please do smile more :-) Works in all browsers, iOS, Android and Windows mobile. Now, when you press enter, you actually don't get 69. You get five characters: 69, 110, 116, 101, 114 When you print those characters, it's spelled out: Enter Now, well... I suppose I could convert that internally to #13 :-) 1 1 recursiveElk and lynkfs reacted to this Share this post Link to post Share on other sites
jarto 428 Report post Posted November 11, 2017 New update available, that fixes this. 2 IElite and recursiveElk reacted to this Share this post Link to post Share on other sites
recursiveElk 24 Report post Posted November 12, 2017 Yeah any solution works and i've seen a lot of debate on either side of chromium forums on the issue. Just wanted to alert for the sake of consistency moving forward. Share this post Link to post Share on other sites
jarto 428 Report post Posted November 12, 2017 3 minutes ago, recursiveElk said: Yeah any solution works and i've seen a lot of debate on either side of chromium forums on the issue. Just wanted to alert for the sake of consistency moving forward. Thank you for doing it. I appreciate it. The aim of SMS is to solve all these kinds of issues and differences inside the RTL so that programmers don't have to write platform specific code. So I'll be more than happy to test and fix any issues like these :-) 2 1 recursiveElk, markus_ja and Czar reacted to this Share this post Link to post Share on other sites