[DO NOT MERGE] Sync app requested orientation on PiP exit
When exiting PiP to fullscreen, SysUI compares the initial rotation
with the screen rotation and skips the animation if they are different,
with the intention that the app should get back to its state prior to PiP.
This generally works well except that app may request
setRequestedOrientation after entering PiP and the initial rotation
SysUI gets in onTaskAppeared would be obsoleted.
This is fixed in this CL by
- Adding a requestedOrientation field in TaskInfo to pass this
information to SysUI, in both onTaskAppeared and onTaskInfoChanged
callbacks
- Sync with the requested orientation as well as display rotation on PiP
exit. Moves also the information we need into PipWindowConfigurationCompact
Video: http://rcll/aaaaaabFQoRHlzixHdtY/gOPXfx5KO9krmzeor49DgG
Bug: 163218295
Test: See video
Change-Id: Idd0b9412dfdfd6fd293a800cded7c7a6b94cafde
5 files changed