commit | b7d459ed78f394ce6a37942f959294d5f74492bc | [log] [tgz] |
---|---|---|
author | Catherine Liang <cathliang@google.com> | Wed Oct 09 21:41:20 2024 +0000 |
committer | Catherine Liang <cathliang@google.com> | Tue Oct 15 19:48:22 2024 +0000 |
tree | 029c6559205e3b8d2fd7798d39c584142460835e | |
parent | dfb649409975234955833425bf6622f4c15f5c9e [diff] |
Preview UI color based on color picker user selection Flag: com.android.systemui.shared.new_customization_picker_ui Test: manually verified Bug: 350718581 Change-Id: I65c220919737d8d71dd5f3c6dc8801861824f853
diff --git a/src/com/android/wallpaper/customization/ui/binder/ColorsFloatingSheetBinder.kt b/src/com/android/wallpaper/customization/ui/binder/ColorsFloatingSheetBinder.kt index e2a8cf3..10bedb3 100644 --- a/src/com/android/wallpaper/customization/ui/binder/ColorsFloatingSheetBinder.kt +++ b/src/com/android/wallpaper/customization/ui/binder/ColorsFloatingSheetBinder.kt
@@ -92,6 +92,17 @@ } } } + + launch { + viewModel.previewingColorOption.collect { colorModel -> + if (colorModel != null) { + colorUpdateViewModel.previewColors( + colorModel.colorOption.seedColor, + colorModel.colorOption.style, + ) + } else colorUpdateViewModel.resetPreview() + } + } } } }