【问题标题】:Custom Preference Including EditText包含 EditText 的自定义首选项
【发布时间】:2011-01-10 09:49:40
【问题描述】:

我正在创建一个包含EditText 的自定义首选项。

问题是当用户单击EdiText 输入建议框打开时EditText 失去焦点。当再次点击EditText进行输入时,直到输入“空格”才会出现问题,这会导致建议框并因此失去焦点。

我所说的建议框是在EditText中输入文字时弹出的框

【问题讨论】:

    标签: android input android-edittext autosuggest


    【解决方案1】:

    您可以通过在 XML 文件中使用 android:inputType="textFilter" 属性来禁用自动建议。

    【讨论】:

      【解决方案2】:

      另一个对我有用的解决方案: 在 AndroidMenifest.xml 中添加 android:windowSoftInputMode="adjustPan" 在活动中。

      在这里找到: http://www.mail-archive.com/android-developers@googlegroups.com/msg132688.html

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 1970-01-01
        • 2018-09-05
        • 1970-01-01
        • 2011-04-03
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 2013-04-13
        相关资源
        最近更新 更多