commit | 509c9a2b6a2e242054e477b831da96edb477c4a9 | [log] [tgz] |
---|---|---|
author | Jordan Demeulenaere <jdemeulenaere@google.com> | Thu Dec 15 11:27:39 2022 +0100 |
committer | Jordan Demeulenaere <jdemeulenaere@google.com> | Thu Dec 15 13:33:01 2022 +0100 |
tree | 9a6b5c479a26004b277d19259ed3359f7dd0d9b1 | |
parent | b85fe2b4a0b178c885bdb4e1d3d193c5d29e01b4 [diff] |
Introduce the FadingBackground modifier This CL introduces an overload of Modifier.background which takes a `alpha: () -> Float` parameter to set the alpha of the background. This should be used when the alpha of the background is animated, to avoid recompositions during an animation. The content of FadingBackground.kt was mostly copy pasted from Background.kt [1]. [1] http://cs/androidx-platform-dev/compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/Background.kt Bug: 242040009 Test: Manual Change-Id: I3296f7bc7382e2afe77a088cfdbefbfae134051d