Mobile Keyboard for Android [NOW WORKING]

Jon

  • *
  • Posts: 17526
This is pretty embarrassing, but I'm unable to figure out how to actually capture the input coming in from the soft keyboard on Android.

It's super easy to get it to show/hide and that was done long ago, but I've yet to find a single page talking about how you actually listen in in the darn thing - anybody know?

« Last Edit: October 24, 2015, 12:05:34 am by Jon »

Innes

  • *
  • Posts: 1961
It appears that soft-keyboard-capture on Android is a tricky topic! I don't know if these links are helpful:
Number 3 is a library that has been written to simplify soft keyboard input.

I can't vouch for any of the information, but hopefully it may be of use to you.
Visit www.TheStencylBook.com - the only published book for learning Stencyl.

svintaj

  • *
  • Posts: 298
Hello! How is this progressing? I tried to use the Android keyboard today but the "Mobile Keyboard Is Pressed"-event returns nothing for me, actually the event does not even fire, so I guess it's not implemented yet? Also the keyboard-layout lacks a "Done"-button, so I can't test the "Mobile Keyboard Is Submitted"-event?

I don't know about the Android API but I found this link, dunno if its usefull but I hope so: http://developer.android.com/guide/topics/text/creating-input-method.html#IMEUI
 
"As the user inputs text with your IME, you can send text to the application by sending individual key events or by editing the text around the cursor in the application's text field. In either case, you use an instance of InputConnection to deliver the text. To get this instance, call InputMethodService.getCurrentInputConnection()."


Dom818

  • *
  • Posts: 1296
Not sure if this can help this bug at all or not, but I found this on the NME/OpenFL forums todays. It seems this person has gotten the keyboard working on android and posted some code for it. http://www.openfl.org/forums/programming-haxe/softkeyboard-handling-android-and-ios/#12129

Jon

  • *
  • Posts: 17526
The code mentions that it will occasionally crash. I'll wait for the author to finish it up.

turritom

  • Posts: 38

« Last Edit: December 09, 2013, 01:53:00 pm by turritom »

riki82

  • Posts: 326
The keyboard will be implemented in the future?
Otherwise, I try alternative  :)

turritom

  • Posts: 38
i have make my own keyboard ;D

Jon

  • *
  • Posts: 17526
Cool - do you have a sample project/demo to show it?

turritom

  • Posts: 38
its not a rocket science

you can test my game under

https://dl.dropboxusercontent.com/u/514672/Gold%20Digga.apk

its work in progress (and still laggy :( )

you see the keyboard if you submit your score .. the buttons are only actors



and each button have this Event



Jon

  • *
  • Posts: 17526
Oh, so you implemented your own keyboard. I thought you meant you integrated the OpenFL extension linked in this topic.

creatiwell

  • Posts: 125
I am looking for same..

"its work in progress (and still laggy :( )" - -- - So many objects on screen :) - Better try to use whole keyboard as picture and just use regions (touch=>region=>reg1) 

And should will work better

Abliblablobla

  • *
  • Posts: 524
Hi everyone,
If someone is still interested, I have just developed a new Android Keyboard extension for Stencyl. This extension has the exact same blocks as the built in keyboard support. Since this is a normal extension, you will find the blocks in the "Extension" tab of the blocks palette. This extension supports the built in keyboard events (add event > mobile > keyboard).

Since there are a lot of different Android devices, I need some help with testing. I would be interested in hearing your feedback about this extension.

Notes:
1) This is an Android extension only! If everything works as expected, the Stencyl team will merge this extension with the built in iOS keyboard support.
2) This is a work in progress that won't be supported by the Stencyl team until it becomes part of the engine.

EDIT: You can find the extension a few posts below.

« Last Edit: September 23, 2014, 01:14:40 pm by Abliblablobla »
.: BuruBuru :.

riki82

  • Posts: 326
Hi everyone,
If someone is still interested, I have just developed a new Android Keyboard extension for Stencyl. This extension has the exact same blocks as the built in keyboard support. Since this is a normal extension, you will find the blocks in the "Extension" tab of the blocks palette. This extension supports the built in keyboard events (add event > mobile > keyboard).

Since there are a lot of different Android devices, I need some help with testing. I would be interested in hearing your feedback about this extension.

Notes:
1) This is an Android extension only! If everything works as expected, the Stencyl team will merge this extension with the built in iOS keyboard support.
2) This is a work in progress that won't be supported by the Stencyl team until it becomes part of the engine.

Fantastic news!
Thanks!

havana24

  • *
  • Posts: 505
I've tried it but the game doesn't compile!
My Website: www.havana24.net