下面提到的代码能够显示键盘,但问题是在按下任何键后,它给了我"body is not activated....."
因为
document.getElementById("userid").focus();
但如果我删除document.getElementById("userid").focus();
键盘将不会生成并且键开始工作
IME的示例代码
SceneSignIn.prototype.handleShow = function (options) {
alert("SceneSignIn.handleShow()");
// this function will be called when the scene manager shows this scene
this.ime_plainText = new IMEShell("userid");
this.ime_passwordText = new IMEShell("password");
document.getElementById("userid").focus();
}
答案 0 :(得分:0)
检查是否:
<a href="javascript:void(0);" id="anchor" onkeydown="main.keyDown(event);"></a>