Introduce config_imeDrawsImeNavBar

This is a follow up CL to my previous CL [1], which used the following
conditions to determine when to let the IME render the back and IME
switcher buttons.

 * InputMethodService#canImeRenderGesturalNavButtons(), and
 * com.android.internal.R.integer.config_navBarInteractionMode == 2

In production, there may be cases when we want to use the previous
mode even if config_navBarInteractionMode remains to be 2.  As a
preparation to support such scenarios, this CL introduces

  config_navBarInteractionMode

as an overlayable resource.  In subsequent CLs, we will start actually
using it.

Anyway there should be no observable behavior change in this CL.

 [1]: I3e7e1f83554444131e2765dc159617bb9e2337c7
      ff7b453ca8

Bug: 216118048
Test: Manually verified as follows
 1. Build aosp_coral-userdebug and flash it
 2. adb shell cmd overlay lookup android android:bool/config_imeDrawsImeNavBar
     => "false"
 3. Enable gestural navigation
 4. adb shell cmd overlay lookup android android:bool/config_imeDrawsImeNavBar
     => "true"
Change-Id: I0651a99b6007a84be63b85b579a85af0f24bb6ec
This commit is contained in:
Yohei Yukawa
2022-02-08 00:53:13 -08:00
parent e429730809
commit b89cbc6f05
6 changed files with 16 additions and 0 deletions

View File

@@ -3658,6 +3658,9 @@
<!-- Controls whether the navigation bar lets through taps. -->
<bool name="config_navBarTapThrough">false</bool>
<!-- Controls whether the IME renders the back and IME switcher buttons or not. -->
<bool name="config_imeDrawsImeNavBar">false</bool>
<!-- Controls whether the side edge gestures can always trigger the transient nav bar to
show. -->
<bool name="config_navBarAlwaysShowOnSideEdgeGesture">false</bool>

View File

@@ -2991,6 +2991,7 @@
<java-symbol type="integer" name="config_navBarInteractionMode" />
<java-symbol type="bool" name="config_navBarCanMove" />
<java-symbol type="bool" name="config_navBarTapThrough" />
<java-symbol type="bool" name="config_imeDrawsImeNavBar" />
<java-symbol type="bool" name="config_navBarAlwaysShowOnSideEdgeGesture" />
<java-symbol type="bool" name="config_navBarNeedsScrim" />
<java-symbol type="bool" name="config_allowSeamlessRotationDespiteNavBarMoving" />

View File

@@ -30,6 +30,9 @@
<!-- Controls whether the navigation bar lets through taps. -->
<bool name="config_navBarTapThrough">true</bool>
<!-- Controls whether the IME renders the back and IME switcher buttons or not. -->
<bool name="config_imeDrawsImeNavBar">true</bool>
<!-- Controls the size of the back gesture inset. -->
<dimen name="config_backGestureInset">30dp</dimen>

View File

@@ -30,6 +30,9 @@
<!-- Controls whether the navigation bar lets through taps. -->
<bool name="config_navBarTapThrough">true</bool>
<!-- Controls whether the IME renders the back and IME switcher buttons or not. -->
<bool name="config_imeDrawsImeNavBar">true</bool>
<!-- Controls the size of the back gesture inset. -->
<dimen name="config_backGestureInset">40dp</dimen>

View File

@@ -30,6 +30,9 @@
<!-- Controls whether the navigation bar lets through taps. -->
<bool name="config_navBarTapThrough">true</bool>
<!-- Controls whether the IME renders the back and IME switcher buttons or not. -->
<bool name="config_imeDrawsImeNavBar">true</bool>
<!-- Controls the size of the back gesture inset. -->
<dimen name="config_backGestureInset">18dp</dimen>

View File

@@ -30,6 +30,9 @@
<!-- Controls whether the navigation bar lets through taps. -->
<bool name="config_navBarTapThrough">true</bool>
<!-- Controls whether the IME renders the back and IME switcher buttons or not. -->
<bool name="config_imeDrawsImeNavBar">true</bool>
<!-- Controls the size of the back gesture inset. -->
<dimen name="config_backGestureInset">32dp</dimen>