yvant
yvant

Reputation: 79

AS3 AIR RequestSoftKeyboard not working on Windows

I tried to launch a virtual keyboard on Windows using this:

_txtInputName = new TextField();
_txtInputName.type = TextFieldType.INPUT;
_txtInputName.needsSoftKeyboard = true;
_txtInputName.addEventListener(FocusEvent.FOCUS_IN, onFocus );

private function onFocus(e:FocusEvent):void
{
    _txtInputName.requestSoftKeyboard();
}

Unfortunaly, the softkeyboard doesn't show up. Am I missing something? Does I have to add something on the application.xml?

Thank you so much!

Upvotes: 0

Views: 824

Answers (1)

BotMaster
BotMaster

Reputation: 2223

TextField is not an object type compatible with native keyboard handling. As a coder using a TextField does mean not using native keyboard at all. SO simple answer to your question is this:

Of course it's not working since it's not mean to.

Next: To provide native keyboard support on the AIR platform the StageText built-in class was implemented and is the one any coder wanting to handle native keyboard should use. http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/text/StageText.html

Upvotes: 1

Related Questions