[flexiglass] Introduce rememberSession {} API
This API allows for composables to associate a `remember` with a session
object, so that the state is maintained even when the composable exits
the composition.
For flexiglass, this is useful because it allows state to be preserved
across scenes; this allows for notification scroll position to be
preserved after going to-then-from Bouncer, for example.
Flag: ACONFIG com.android.systemui.scene_container DEVELOPMENT
Test: (with follow-up CL)
1. Open Shade
2. Scroll notifications
3. Go to Bouncer
4. Return to Shade, observe scroll state preserved
Change-Id: I37ed03d0dd95d6e01d064a693a46f73cebb2ff0b
2 files changed