ThemePicker: Fix incorrect logic in wallpapersColorsChanged
Fixes a crash when lockscreen wallpaper is different from home screen wallpaper, or some other unknown case. Change-Id: Iab496d67f7ab5f363102b633a0708867df0121d6 Signed-off-by: Adithya R <gh0strider.2k18.reborn@gmail.com> Reviewed-on: https://review.statixos.com/c/android_packages_apps_Statix_ThemePicker/+/7729 Tested-by: Anay Wadhera <anay1018@gmail.com> Reviewed-by: Sourajit Karmakar <sourajit@live.com>
This commit is contained in:
parent
de4619e5c0
commit
3eb62d0ee6
|
@ -201,8 +201,8 @@ class ColorSectionController(
|
||||||
}
|
}
|
||||||
val wallpaperColors3 = mColorManager.mHomeWallpaperColors
|
val wallpaperColors3 = mColorManager.mHomeWallpaperColors
|
||||||
val colorProvider = mColorManager.mProvider as ColorProvider
|
val colorProvider = mColorManager.mProvider as ColorProvider
|
||||||
val wallpapersColorsChanged = (colorProvider.homeWallpaperColors == wallpaperColors3
|
val wallpapersColorsChanged = (colorProvider.homeWallpaperColors != wallpaperColors3
|
||||||
) || (colorProvider.lockWallpaperColors == wallpaperColors2)
|
) || (colorProvider.lockWallpaperColors != wallpaperColors2)
|
||||||
if (wallpapersColorsChanged) {
|
if (wallpapersColorsChanged) {
|
||||||
colorProvider.homeWallpaperColors = wallpaperColors3
|
colorProvider.homeWallpaperColors = wallpaperColors3
|
||||||
colorProvider.lockWallpaperColors = wallpaperColors2
|
colorProvider.lockWallpaperColors = wallpaperColors2
|
||||||
|
|
Loading…
Reference in New Issue