commit | 47ec2f41ffc520a87e565adae0081bccc9a08253 | [log] [tgz] |
---|---|---|
author | Catherine Liang <cathliang@google.com> | Mon Oct 21 19:04:07 2024 +0000 |
committer | Android (Google) Code Review <android-gerrit@google.com> | Mon Oct 21 19:04:07 2024 +0000 |
tree | 7939e24e10bc986c6423faf3187ea5accb1628c6 | |
parent | bc72babf89d9cd5030c8425cc6c2ddc51a7e8c39 [diff] | |
parent | b7d459ed78f394ce6a37942f959294d5f74492bc [diff] |
Merge "Preview UI color based on color picker user selection" into main
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() + } + } } } }