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

Skip to content
Commit 4b9cd743 authored by Jordan Demeulenaere's avatar Jordan Demeulenaere
Browse files

Refactor animate(Scene|Element)FooAsState (1/2)

This CL refactors animate(Scene|Element)FooAsState so that it does not
need to access the associated Element during composition. This should
allow the simplification of Modifier.element itself and remove all calls
to Snapshot.withoutReadObservation {}.

A major side effect of this CL is that reading the returned State value
during composition will now throw an exception. This is a good thing,
because animated values should never be read during composition anyways,
and before this CL we could get invalid values that were 1 frame behind.

Bug: 317026105
Test: AnimatedSharedAsStateTest
Flag: N/A
Change-Id: I20d247e9cc6a8f48e8f611421e5b3d56fc091dba
parent c49e33d0
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment