Last modified: 2014-09-04 00:14:40 UTC
Key events fire without key codes (understandable as you can 'swipe' whole words) and backspace fires no key[up|down|press] event at all.
Oy.
There is an 'input' event which fires, but this doesn't solve the problem of prevent the default backspace behaviour.
See https://code.google.com/p/chromium/issues/detail?id=118639 for pitchfork waving, including a complaint from the Microsoft Office Web Apps team who are having the same problem.
Not quite true, see http://jsbin.com/alAKaNaZ/5 Backspace fires a keydown with keyCode 0 (same as every other key event) but not when whitespace is deleted. See https://code.google.com/p/chromium/issues/detail?id=184812
"No key event is generated when the BACKSPACE key is pressed outside of composition, in other words, when AdapterInputConnection.deleteSurroundingText is called. In the reported bug, since the text field is empty, thus IME is not in the composition mode, thus pressing the BACKSPACE key triggers deleteSurroundingText and thus no key event is generated. A cl that generates key events in deleteSurroundingText with a dummy keycode is under review at https://codereview.chromium.org/348413003/."
It looks like the above commit to Chrome for Mobile has been merged, which solves the most serious case (no event fired at all). We are still left with the general problem of IME deletion.
(In reply to Ed Sanders from comment #6) > It looks like the above commit to Chrome for Mobile has been merged, which > solves the most serious case (no event fired at all). It doesn't "solve" it perfectly, as OS update lag for Android devices is notoriously slow (or non existent), and app update take-up is apparently poor. Is there a sane work-around we could do? > We are still left with the general problem of IME deletion. Yeah. :-(
OS update is not an issue, just app.
Note that Android 4.4's WebView is based on the Chromium engine, and unlike the standalone Chrome app it only gets updated with the OS. Might want to check whether the stock Android browser on non-Google-branded 4.4.x devices is also affected. (Nexus devices seem to leave out the AOSP default browser in favor of Chrome, but I see a customized version on Samsung Galaxy branded devices for instance.)