Per-app override sandboxing View API to Activity bounds
Some applications assume that they occupy the whole screen and therefore use the display coordinates in their calculations. This can lead to shifted or out of bounds UI elements in case the activity is Letterboxed or is in split-screen mode. OVERRIDE_SANDBOX_VIEW_BOUNDS_APIS change id forces the packages it is applied to sandbox View API to Activity bounds for: android.view.View#getBoundsOnScreen android.view.View#getLocationOnScreen android.view.View#getWindowVisibleDisplayFrame android.view.View#getWindowDisplayFrame This sandboxing is happening indirectly in android.view.ViewRootImpl through android.view.ViewRootImpl#getWindowVisibleDisplayFrame, android.view.ViewRootImpl#getDisplayFrame respectively. Application developers can opt-out of this treatment by using the following configuration in their manifest: <application> <property android:name= "android.window.PROPERTY_COMPAT_ALLOW_SANDBOXING_VIEW_BOUNDS_APIS" android:value="false"/> </application> Test: atest CtsWindowManagerDeviceTestCases:CompatChangeTests Bug: 234799838 Change-Id: Ia064d26b46402a04056f498a1ed5c090a6d1b965
Loading
Please register or sign in to comment