summaryrefslogtreecommitdiff
path: root/tools/aapt2/java/JavaClassGenerator.cpp
diff options
context:
space:
mode:
authorJorim Jaggi <jjaggi@google.com>2017-03-21 17:36:26 +0100
committerJorim Jaggi <jjaggi@google.com>2017-04-03 15:36:29 +0200
commitaea6b74e17a0f7b105999adad50dd20eac17df35 (patch)
tree80f9df98eb54ec096a2d56061f78c10012264b31 /tools/aapt2/java/JavaClassGenerator.cpp
parent91232840aa1cebd4586ab2437243345a05f34fa4 (diff)
Handle case when snapshot dimensions don't match
If the snapshot starting window has different dimensions than the snapshots we have taken, we do the following: - Create a child Surface that has exactly the dimensions of the snapshot. - We fill the parent surface with the app background color, as well as all screen background decorations (status bar background, navigation bar background). - We also clip of the status bar/navigation bar background in some cases, as it looks ugly if it's not behind the system bars. - Furthermore, we inherit all layout flags on the window and all layout relevant SystemUI flags on the window such that it's very likely that the size will match, and the system bars are drawn correctly. - In order to make the transition from the snapshot to the real window a bit more predictable/less messy, we enforce a minimum duration the snapshot is visible, which is slightly more than our app transitions. Test: TaskSnapshotSurfaceTest Test: Open app, go home, go landscape, open app again Test: Go to multi-window, open app from recents with a snapshot taken in fullscreen. Fixes: 36703868 Change-Id: Ia2d4add6971a18ab7aa2942d2b644d6e87a402af
Diffstat (limited to 'tools/aapt2/java/JavaClassGenerator.cpp')
0 files changed, 0 insertions, 0 deletions