Fix issue with touches falling through nav bar in 3 button nav

- This fixes a regression from ag/17185260 where we are no longer
  returning early when computing the touchable region in different
  nav bar states.

Bug: 249053817
Test: Enable 3 button nav, dumpsys input and verify the touchable
      region matches the window frame
Change-Id: Ib5767494973bbb23b3125988b94dcf46a2a6df24
This commit is contained in:
Winson Chung
2022-09-27 18:14:21 +00:00
parent 5c4704b781
commit 6ceb084c7b

View File

@@ -541,10 +541,12 @@ public class NavigationBar extends ViewController<NavigationBarView> implements
if (!mImeVisible) {
// IME not showing, take all touches
info.setTouchableInsets(InternalInsetsInfo.TOUCHABLE_INSETS_FRAME);
return;
}
if (!mView.isImeRenderingNavButtons()) {
// IME showing but not drawing any buttons, take all touches
info.setTouchableInsets(InternalInsetsInfo.TOUCHABLE_INSETS_FRAME);
return;
}
}