Include insets in bounds with restricted aspect ratio
The target of aspect ratio is app bounds. The output of
applyAspectRatio is raw bounds. Because the insets of all
sides will be clipped when resolving the configuration by
computeConfigResourceOverrides, the raw aspect ration bounds
should also include insets of all sides. Otherwise it wastes
the available space of insets area.
Fixes: 159745191
Fixes: 189558761
Test: SizeCompatTests#testOverrideMinAspectRatioLowerThanManifest
CtsWindowManagerDeviceTestCases:AspectRatioTests
Test: Set screen size to 1000x2200 with gesture navigation.
Launch a landscape app with max aspect ratio 1.9.
The bottom of screen shouldn't have an empty area.
Change-Id: I55b9662425173f0df086439e121395682d951b60
2 files changed