简体   繁体   English

专注于Android 2.3上的EditText时键盘不显示

[英]Keyboard not showing up when focused on EditText on Android 2.3

I have run into an issue where on Android 2.3 the soft keyboard does not show up when focused on a Edit Text. 我遇到了一个问题,在Android 2.3上,当专注于“编辑文本”时,软键盘不显示。

The EditText is part of a layout for a fragment which is nested in another fragment EditText是一个片段的布局的一部分,该片段嵌套在另一个片段中

    <EditText
        android:id="@+id/name"
        android:layout_width="fill_parent"
        android:layout_height="wrap_content"
        android:ems="10"
        android:maxLength="30"
        android:singleLine="true" >
        <requestFocus />
    </EditText>

I can get they keyboard to show up if i lock and unlock the screen. 如果锁定和解锁屏幕,我可以让他们的键盘显示出来。 I have attempted to manually unfocus and focus and tried to manually open the keyboard. 我试图手动取消对焦和聚焦,并尝试手动打开键盘。 All with no luck. 一切都没有运气。

I would prefer to not have to programmatically show the keyboard. 我希望不必以编程方式显示键盘。

Any help is appreciated 任何帮助表示赞赏

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM