[1/n] Camera Compat: Force rotate activities
Camera compatibility treatment that handles orientation mismatch between camera buffers and an app window that can lead to camera issues like sideways or stretched viewfinder. The treatment is enabled for internal displays that have ignoreOrientationRequest display setting enabled and when a flag config_windowManagerCameraCompatTreatmentEnabled is true. It's only applied to activities that have fixed orientation and are in fullscreen. Main parts of the solution: - Listen for the camera changes in DisplayRotationCompatPolicy to trigger orientation update when necessary - Incorporate DisplayRotationCompatPolicy#getOrientation in orientation resolution logic in DisplayContent - Don't trigger orientation updates too quickly to avoid orientation flickering during the camera flip or fold-unfold for foldable devices Bug: 218352945 Test: atest WmTests:DisplayRotationCompatPolicyTests Change-Id: Iaa3a3efa4e0fa89fbb58c7dbc59c125600972224
Loading
Please register or sign in to comment