Anybody have any ideas? Still struggling with this... :( - Dan
On Mon, Jun 29, 2009 at 5:10 PM, Dan Sherman <[email protected]> wrote: > Recently was updating a game implementing SurfaceView to handle input > from the soft-keyboard. One of the first things we noticed was that > the enter/return key is handled by the IME and not passed to our app > (we do our own handling of all keypresses). > > I've wrapped the classes necessary for normal function to be 1.1 safe > (like InputMethodManager) behind static checks... And they all work on > 1.1... However, to get the IME to pass enter/return, we add the > IME_ACTION_NONE in the onCreateInputConnection callback.. > > As soon as that code is defined (regardless of getting called), we get > insta-VerifyExceptions (makes sense). My question is, is there any > way to wrap this callback to be 1.1 safe, or is there any way to > specify the IME_ACTION_NONE ahead of time for SurfaceView's that > explicitly call InputMethodManager.showSoftInput(<MySurfaceView>, > InputMethodManager.SHOW_FORCED) > > > This is the code we need run: > public InputConnection onCreateInputConnection(EditorInfo outAttrs) > { > outAttrs.imeOptions |= EditorInfo.IME_ACTION_NONE; > return null; > } > > > Right now we're stuck having to decide to support softkeyboards, and > drop support entirely for 1.1, or drop support for softkeyboards > entirely to support 1.1 (only because of a single line)... > > Any help would be greatly appreciated... :) > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---

