Enable 'dim in dark theme' by default.

This commit is contained in:
Alex Hart
2021-01-22 09:13:12 -04:00
parent b95083fe92
commit dbac9bf9f6
2 changed files with 4 additions and 4 deletions

View File

@@ -85,7 +85,7 @@ public class ChatWallpaperFragment extends Fragment {
R.string.ChatWallpaperFragment__clear,
() -> {
viewModel.setWallpaper(null);
viewModel.setDimInDarkTheme(false);
viewModel.setDimInDarkTheme(true);
viewModel.saveWallpaperSelection();
});
});
@@ -95,7 +95,7 @@ public class ChatWallpaperFragment extends Fragment {
R.string.ChatWallpaperFragment__reset,
() -> {
viewModel.setWallpaper(null);
viewModel.setDimInDarkTheme(false);
viewModel.setDimInDarkTheme(true);
viewModel.resetAllWallpaper();
});
});

View File

@@ -32,7 +32,7 @@ public class ChatWallpaperViewModel extends ViewModel {
this.recipientId = recipientId;
ChatWallpaper currentWallpaper = repository.getCurrentWallpaper(recipientId);
dimInDarkTheme.setValue(currentWallpaper != null && currentWallpaper.getDimLevelForDarkTheme() > 0f);
dimInDarkTheme.setValue(currentWallpaper == null || currentWallpaper.getDimLevelForDarkTheme() > 0f);
enableWallpaperControls.setValue(hasClearableWallpaper());
wallpaper.setValue(Optional.fromNullable(currentWallpaper));
}
@@ -65,7 +65,7 @@ public class ChatWallpaperViewModel extends ViewModel {
ChatWallpaper globalWallpaper = SignalStore.wallpaper().getWallpaper();
this.wallpaper.setValue(Optional.fromNullable(globalWallpaper));
this.dimInDarkTheme.setValue(globalWallpaper != null && globalWallpaper.getDimLevelForDarkTheme() > 0);
this.dimInDarkTheme.setValue(globalWallpaper == null || globalWallpaper.getDimLevelForDarkTheme() > 0);
}
enableWallpaperControls.setValue(false);