【问题标题】:How to prevent Title bar hiding when keyboard in active?键盘处于活动状态时如何防止标题栏隐藏?
【发布时间】:2012-05-13 19:36:14
【问题描述】:

我在 TabActivity 中有一个表单(滚动视图),标签出现在页面底部,并且我在页面底部有一个 EditText 元素。每当用户想要输入文本时,总 UI 会随着标题栏移到顶部。有没有可能阻止它?

【问题讨论】:

    标签: android


    【解决方案1】:

    尝试将android:windowSoftInputMode 设置为清单中的活动。否则将布局更改为相对并使您的 EditText android:layout_alignParentBottom="true"

    参考这个Example

    【讨论】:

      【解决方案2】:

      在您的活动中使用 android manifest 中的 android:windowSoftInputMode="adjustPan" 或引用 SoftInputMode documentation。

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 2021-01-07
        • 1970-01-01
        • 1970-01-01
        • 2016-07-03
        • 1970-01-01
        • 1970-01-01
        • 2017-05-25
        • 1970-01-01
        相关资源
        最近更新 更多