Fix back button not touchable in SUW

Since NavbarButtonsViewController already checks visibility of buttons before adding them to the touchableRegion, we can remove teh isThreeButton() check.

Test: run adb shell am start -a android.intent.action.MAIN -n com.google.android.setupwizard/.SetupWizardTestActivity, then press back button and ensure it gives visual feedback (even though there's no page to go back to in this test activity).
Bug: 191846922
Change-Id: I10d3d046cd2d14017638a2c71ea6b9fe228fadfc
This commit is contained in:
Tony Wickham
2021-08-30 09:23:01 -07:00
parent f60c822de7
commit 906def495f

View File

@@ -123,11 +123,9 @@ public class TaskbarDragLayerController {
*/
public void updateInsetsTouchability(InsetsInfo insetsInfo) {
insetsInfo.touchableRegion.setEmpty();
if (mActivity.isThreeButtonNav()) {
// Always have nav buttons be touchable
mControllers.navbarButtonsViewController.addVisibleButtonsRegion(
mTaskbarDragLayer, insetsInfo.touchableRegion);
}
// Always have nav buttons be touchable
mControllers.navbarButtonsViewController.addVisibleButtonsRegion(
mTaskbarDragLayer, insetsInfo.touchableRegion);
if (mTaskbarDragLayer.getAlpha() < AlphaUpdateListener.ALPHA_CUTOFF_THRESHOLD) {
// Let touches pass through us.