Merge "Add new callback for when activity rotates" into rvc-dev

This commit is contained in:
Vinit Nayak
2020-06-04 04:21:10 +00:00
committed by Android (Google) Code Review
6 changed files with 49 additions and 0 deletions

View File

@@ -216,4 +216,14 @@ oneway interface ITaskStackListener {
* in {@link android.content.pm.ActivityInfo}.
*/
void onTaskRequestedOrientationChanged(int taskId, int requestedOrientation);
/**
* Called when a rotation is about to start on the foreground activity.
* This applies for:
* * free sensor rotation
* * forced rotation
* * rotation settings set through adb command line
* * rotation that occurs when rotation tile is toggled in quick settings
*/
void onActivityRotation();
}

View File

@@ -199,4 +199,8 @@ public abstract class TaskStackListener extends ITaskStackListener.Stub {
@Override
public void onTaskRequestedOrientationChanged(int taskId, int requestedOrientation) {
}
@Override
public void onActivityRotation() {
}
}