Rockchip android10.1默认开启虚拟键盘
- 问题描述
- 解决方法
郑重声明:本人原创博文,都是实战,均经过实际项目验证出货的
转载请标明出处:攻城狮2015
Platform: Rockchip
OS:Android 10.1
Kernel: 4.19
问题描述
客户需要在插上外接实体键盘的时候,也需要显示虚拟键盘,而不是隐藏虚拟键盘
解决方法
+++ b/frameworks/base/packages/SettingsProvider/res/values/defaults.xml
@@ -126,7 +126,7 @@
<integer name="def_multi_press_timeout_millis">300</integer>
<!-- Default for Settings.Secure.SHOW_IME_WITH_HARD_KEYBOARD -->
- <bool name="def_show_ime_with_hard_keyboard">false</bool>
+ <bool name="def_show_ime_with_hard_keyboard">true</bool>
有些按照以上修改,可能还不行,还需要看下TvSettings里面的packages/apps/TvSettings/Settings/res/xml/physical_keyboard_settings.xml中的默认值
packages/apps/TvSettings/Settings/res/xml/physical_keyboard_settings.xml
16 <PreferenceScreen
17 xmlns:android="http://schemas.android.com/apk/res/android"
18 android:title="@string/physical_keyboard_title">
19 <!-- Additional preference screens are inserted here programmatically
20 with low order values to set the key map of each attached keyboard. -->
21 <PreferenceCategory
22 android:key="keyboard_assistance_category"
23 android:title="@string/keyboard_assistance_category"
24 android:layout="@layout/preference_category_compact_layout">
25 <SwitchPreference
26 android:key="show_virtual_keyboard_switch"
27 android:title="@string/show_ime"
28 android:summary="@string/show_ime_summary"
29 android:defaultValue="false" />
30
31 <Preference
32 android:key="keyboard_shortcuts_helper"
33 android:title="@string/keyboard_shortcuts_helper"
34 android:summary="@string/keyboard_shortcuts_helper_summary" />
35 </PreferenceCategory>
36 </PreferenceScreen>
郑重声明:本人原创博文,都是实战,均经过实际项目验证出货的
转载请标明出处:攻城狮2015