当我在Android中点击edittextview键盘没有显示?我在、键盘、Android、edittextview

由网友(╭╮)分享简介:当我点击然后一些时间键盘显示或有时键盘都没有显示edittextview。When i click on the edittextview then some times keyboard shown or some times keyboard are not shown.在Android 2.1的显示它的键盘时...

当我点击然后一些时间键盘显示或有时键盘都没有显示edittextview。

When i click on the edittextview then some times keyboard shown or some times keyboard are not shown.

在Android 2.1的显示它的键盘时,我点击edittextview

In android 2.1 it show the keyboard when i click on the edittextview

但是当我开始在Android 2.2同样的应用它,然后它不会显示键盘。

but when i start same application it on android 2.2 then it not show the keyboard.

帮助我如何证明这个问题。

Help me how to show that problem.

推荐答案

确定,这可能是一个迟到的反应,但它的工作。

OK, This might be a late response, but it worked.

我见过在Android 2.1和2.3.x这一问题(而不是其他版本的软件开发工具包的测试)。

I have met this problem on android 2.1 and 2.3.x(not tested on other versions of SDKs).

我注意到一个奇怪的事情,当我点击的EditText无法打开键盘,我pressed BACK按钮来显示一个警告对话框,然后我取消(关闭)它,然后再次点击的EditText,现在键盘被带到生活了。

I noticed a strange thing that when my click on the EditText was unable to open the keyboard, I pressed the BACK button to show an alert dialog and then I canceled(closed) it, and clicked the EditText again, now the keyboard was brought to life again.

这是我可以得出这样的结论键盘将始终显示为的EditText如果EditText上没有的 previously 自己的焦点(显示在EditText上查看警报对话框将使的EditText失去焦点)。

From that I can conclude that the keyboard will always show for the EditText if the EditText does not previously own focus(showing an alert dialog over the EditText view will make the EditText to lose focus).

所以调用下面的函数在您的EditText当它被带到面前:

so call the function below on your EditText when it is brought to front:

mEditText.clearFocus();

parentViewThatContainsEditTextView.clearFocus();
阅读全文

相关推荐

最新文章