Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 57ec0598 authored by Matías Hernández's avatar Matías Hernández
Browse files

Keep legacy suppressed-effect Policy fields in MODES_UI

NMS calculates a set of suppressed visual effects based on the supplied Policy, the current Policy, and the targetSdk of the caller. That result can include a mix of "legacy" (pre-API-28) and "new" (post-API-28) effects. However, legacy effect cannot be stored in a ZenPolicy, which is what MODES_UI uses for the manual rule. Therefore, we store them in a different attribute and restore them on read, keeping the same behavior as pre-MODES_UI.

Note that this behavior, while unchanged, is still a bit inconsistent overall. For example, these legacy effects are not preserved in the consolidated policy (but always recalculated from the new ones).

Bug: 356334282
Test: atest ZenModeHelperTest ZenModeConfigTest NotificationManagerZenTest CtsLegacyNotification27TestCases
Flag: android.app.modes_ui

Change-Id: Iad1444ee2c3d69dedd24c14cafc7ff86783c2f07
parent 511996d0
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment