Reputation: 660
I've got an html form text field that normally handles key up/down events. However, just noticed that if you use the mic assistant in ios5 mobile safari to fill the field for you, the key up/down isn't getting triggered.
Anyone know what event should be bound to instead to handle? Currently using jQuery w/o jQuery Mobile (file size restrictions) - plain JS would be super too. Am hoping I don't need to resort to polling.
Fiddle of demo code: http://jsfiddle.net/jfroom/wAdC8/5/
You can get to the mic functionality by clicking on the little mic icon on the text input tray.
Thanks in advance.
Upvotes: 2
Views: 2164
Reputation: 660
Solution in jquery below. (I'm sure there's a pure JS equivalent very similar to this.)
$("#myinput").bind("input paste", handleChange);
Demo here: http://jsfiddle.net/jfroom/JLQLV/31/
.bind("input propertychange") also works, but can dilute other key up/down events. Thanks to SLaks for this find Jquery / JS bind "paste" event handler to input textbox
Upvotes: 5