Question

This may apply to other mobile operating environments than just Symbian... However, the issue is that when changing a text area field I'd like to update a count as I type. This is easy to accomplish in most browsers with something like this on the textarea tag:

onkeyup="document.getElementById('size').innerHTML=this.value.length;

However, in Symbian, the onkeyup event does not appear to fire normally (it seems like all input is buffered or something). Now I can replace this with:

onblur="document.getElementById('size').innerHTML=this.value.length;

...This works fine but of course only updates the DIV when focus is lost (which is better than nothing but not as nice as having it update as you type).

Has anyone encountered an issues like this specifically on Symbian? On any other mobile browser? Any ideas/solutions?

I've been hating Symbian since I've started using it -- there are so many weirdnesses like this in their APIs. I'll vote up anyone who gripes about Symbian. ;-)

Was it helpful?

Solution

In Symbian's version of WebKit, the keyboard events are royally messed up. The only reliable way to handle them is to set the handler on the document [!]. Now, I have NOT tried that in the situation where textarea has focus but it definitely works with simpler controls. Basically, you use the onfocus and onblur to associate/disassociate the control-specific event handlers with the document. Of course if you want to create a reusable widget that way, you're in for a sea of hurt :(

OTOH, if you gripe about Symbian's little keyboard quirk, take a gander at mouse events in Android's mini-Chrome... those go under the FUBAR heading!

...Max...

PS. If you need more help: max-at-motovilov-dot-com. You should be able to google for this issue on forum.nokia.com but the info there ain't plentiful... it's all trial and error.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top