Fix digital wellbeing banner position in portrait mode
The banner should be aligned to the start of the screen, not the center. This CL fixes DWB position for split tasks when device is unfolded. Change-Id: I0544b4a8eb85b00196373c8a4368e680abab222b Fix: 348200661 Bug: 345789862 Flag: EXEMPT bugfix Test: Manual. Add a Digital Wellbeing (DWB) timer to 2 apps. Open these two apps in split mode. Unfold the device and go to Overview. The DWB banner should aligned correctly.
This commit is contained in:
@@ -259,7 +259,8 @@ public class PortraitPagedViewHandler extends DefaultPagedViewHandler implements
|
||||
return new Pair<>(translationX, translationY);
|
||||
}
|
||||
|
||||
bannerParams.gravity = BOTTOM | ((deviceProfile.isLandscape) ? START : CENTER_HORIZONTAL);
|
||||
bannerParams.gravity =
|
||||
BOTTOM | (deviceProfile.isLeftRightSplit ? START : CENTER_HORIZONTAL);
|
||||
|
||||
// Set correct width
|
||||
if (desiredTaskId == splitBounds.leftTopTaskId) {
|
||||
|
||||
Reference in New Issue
Block a user