Re-enable home screen rotation

Launcher home screen rotation now works with fixed
transform. When using Quickstep while holding
the phone from an orientation different than
the orientation of the touch, the overview
shown will be that of the phone orientation,
not the touch orientation.
Easier to see this be quickswitching from
portrait to landscape app, turning phone, then
going to overview from the original region you
swiped.

Fixes: 150214193
Test: Created test apps and fixed them
to various rotations to test.

Change-Id: Ic6565cd0ed33c951f45ccb97278045c6070e438e
This commit is contained in:
Vinit Nayak
2020-04-01 12:37:40 -07:00
parent a976a2212d
commit 326d93bd56
15 changed files with 294 additions and 123 deletions

View File

@@ -77,6 +77,11 @@ public class PortraitPagedViewHandler implements PagedOrientationHandler {
return displacement < 0;
}
@Override
public boolean isLayoutNaturalToLauncher() {
return true;
}
@Override
public void adjustFloatingIconStartVelocity(PointF velocity) {
//no-op
@@ -180,7 +185,7 @@ public class PortraitPagedViewHandler implements PagedOrientationHandler {
}
@Override
public void offsetTaskRect(RectF rect, float value, int displayRotation) {
public void offsetTaskRect(RectF rect, float value, int displayRotation, int launcherRotation) {
if (displayRotation == Surface.ROTATION_0) {
rect.offset(value, 0);
} else if (displayRotation == Surface.ROTATION_90) {