With this CL, you can let ThemedNavBarKeyboard call
InputMethodService#setBackDisposition(int)
with either the following values
* BACK_DISPOSITION_DEFAULT
* BACK_DISPOSITION_ADJUST_NOTHING
so that you can see how those two flags work.
Bug: 213337792
Test: Manually verified as follows
1. Flash aosp_coral-userdebug into the device
2. make -j ThemedNavBarKeyboard
3. adb install -r $ANDROID_PRODUCT_OUT/system/app/ThemedNavBarKeyboard/ThemedNavBarKeyboard.apk
4. adb shell ime enable com.example.android.themednavbarkeyboard/.ThemedNavBarKeyboard
5. adb shell ime set com.example.android.themednavbarkeyboard/.ThemedNavBarKeyboard
6. Tap any edit field
7. Make sure that the back button is left-pointing triangle
8. Tap "BACK_DISPOSITION_ADJUST_NOTHING" on the IME
9. Make sure that the back button is down-pointing triangle
Change-Id: I71aa1dd23d72e8891cb3887efe5db1a48b6a017d
With this CL, ThemedNavBarKeyboard sameple IME will have an explicitly
set targetSdkVersion=31 so that it can be installed on older version
of Android OSes.
This CL also explicitly sets "android:exported", which has been
required in AndroidManifest.xml since API 31.
Fix: 211463997
Test: Manually verified as follows
1. Flash SQ1A.211205.008 aosp_coral-userdebug into coral
2. make -j ThemedNavBarKeyboard
3. adb install -r $ANDROID_PRODUCT_OUT/system/app/ThemedNavBarKeyboard/ThemedNavBarKeyboard.apk
Change-Id: Idd88031a6b65cca58add8abe42794bc5f01b1973
With Ib8f4045b9e8e7bf65c13437133f114d91d0cb050 navbar always has
contrast thereby creating a solid navbar. However, for IMEs that wish to
draw a gradient, will need to have this disabled.
This change disables contrast for extended navbar gradient.
Fix: 130809016
Test: Manually verified:
1. m -j ThemedNavBarKeyboard
2. Install and enable
3. Click "Extended dark nav bar" and verify gradient is visible.
Change-Id: I511bdcde0ef57c1484faace484db262b49fdfe16
This CL adds a sample IME that demonstrates how an IME can now control
the appearance of bottom navigation bar like typical Activities can
do.
This sample IME covers the following 3 use cases to control the
appearance of bottom navigation bar.
A. (Bottom) navigation bar has solid background color.
Like typical Activities, IMEs can
- call Window#setNavigationBarColor() to change the background
color. (Bug 25706186)
- set SYSTEM_UI_FLAG_LIGHT_NAVIGATION_BAR to tell the SysUI to
optimize the navigation bar button colors. (Bug 69002467)
B. (Bottom) navigation background is seamlessly extended from the main
InputView of the IME, like typical Activities can do with
SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION. Note that essentially this
is a super set of the mode A, because IMEs (and apps) can also fill
the navigation bar region with a solid color in this mode.
C. The appearance of (bottom) navigation bar is controlled by the
target application, not by the IME.
- This is useful for floating IME (Bug 22564251).
Bug: 25706186
Bug: 69002467
Test: Build and manually test as follows.
1. make -j ThemedNavBarKeyboard
2. adb install -r $OUT/system/app/ThemedNavBarKeyboard/ThemedNavBarKeyboard.apk
3. adb shell ime enable com.example.android.themednavbarkeyboard/.ThemedNavBarKeyboard
4. adb shell ime set com.example.android.themednavbarkeyboard/.ThemedNavBarKeyboard
Change-Id: I4b10a19641bd3ce6c43e7629404b6f202d4186e8