From f210a1754aa3d7ce94325e11a2579c1d738578bd Mon Sep 17 00:00:00 2001 From: Don Turner Date: Fri, 21 Oct 2022 21:52:43 +0100 Subject: [PATCH] Add note about b/221643630 --- .../nowinandroid/feature/settings/SettingsViewModel.kt | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/feature/settings/src/main/java/com/google/samples/apps/nowinandroid/feature/settings/SettingsViewModel.kt b/feature/settings/src/main/java/com/google/samples/apps/nowinandroid/feature/settings/SettingsViewModel.kt index 7990a96c0..fa159b555 100644 --- a/feature/settings/src/main/java/com/google/samples/apps/nowinandroid/feature/settings/SettingsViewModel.kt +++ b/feature/settings/src/main/java/com/google/samples/apps/nowinandroid/feature/settings/SettingsViewModel.kt @@ -48,10 +48,11 @@ class SettingsViewModel @Inject constructor( .stateIn( scope = viewModelScope, // Starting eagerly means the user data is ready when the SettingsDialog is laid out - // for the first time. Without this the layout is done using the "Loading" text, - // then replaced with the user editable fields once loaded, however, the layout - // height doesn't change meaning all the fields are squashed into a small + // for the first time. Without this, due to b/221643630 the layout is done using the + // "Loading" text, then replaced with the user editable fields once loaded, however, + // the layout height doesn't change meaning all the fields are squashed into a small // scrollable column. + // TODO: Change to SharingStarted.WhileSubscribed(5_000) when b/221643630 is fixed started = SharingStarted.Eagerly, initialValue = Loading )