Make sure work button is collapsed when keyboard is up upon going to app drawer

Call shrink so that work button is collapsed when keyboard is up.

bug:361589193
Test - manual: video before:https://drive.google.com/file/d/1OChJkEJEWrsuUtEaac2jtc15uGkOeGAm/view?usp=sharing
after: https://drive.google.com/file/d/1DXGia25u4JzWRLTiwqlKQu8TYjyL9SEI/view?usp=sharing
Flag: com.android.launcher3.work_scheduler_in_work_profile

Change-Id: Ifafb76b61f0d2a5e9c6b60519adc300c911b20dc
This commit is contained in:
Brandon Dayauon
2024-11-01 13:27:48 -07:00
parent bfd02bb36a
commit 1fa2840e82

View File

@@ -188,8 +188,10 @@ public class WorkUtilityView extends LinearLayout implements Insettable,
WindowInsetsCompat.toWindowInsetsCompat(insets, this);
if (windowInsetsCompat.isVisible(WindowInsetsCompat.Type.ime())) {
setInsets(mImeInsets, windowInsetsCompat.getInsets(WindowInsetsCompat.Type.ime()));
shrink();
} else {
mImeInsets.setEmpty();
extend();
}
updateTranslationY();
return super.onApplyWindowInsets(insets);