Revert "STL ElementStateScope exposes lastSize()"
This reverts commit 1faa0111. Reason for revert: Not needed anymore after ag/34941048 Remove `ElementKey.lastSize()` from public API, this API was initially introduced with ag/32945988. The function was backed by a `mutableStateOf` to provide an element's current size during transitions. However, we cannot make assumptions about when this state might be read by consumers. If it is read after the layout phase, it can trigger an additional composition/layout pass, leading to a series of unexpected bugs and performance issues (see b/431146033). To prevent this, `Element.State.lastSize` is no longer a `mutableStateOf`. The public API and its corresponding tests are also removed. Test: Manually tested on the demo app Bug: 419520966 Bug: 404526497 Flag: com.android.systemui.scene_container Change-Id: I8138ddba0234ea43d7433fb3b7c4169ce315d5b1
Loading
Please register or sign in to comment