kopia lustrzana https://github.com/ryukoposting/Signal-Android
Fix several ChatColors issues.
rodzic
c794b5c2e7
commit
35930fb23a
|
@ -1533,6 +1533,7 @@ public final class ConversationItem extends RelativeLayout implements BindableCo
|
||||||
|
|
||||||
if (messageRecord.isOutgoing() &&
|
if (messageRecord.isOutgoing() &&
|
||||||
!hasNoBubble(messageRecord) &&
|
!hasNoBubble(messageRecord) &&
|
||||||
|
!messageRecord.isRemoteDelete() &&
|
||||||
bodyBubbleCorners != null)
|
bodyBubbleCorners != null)
|
||||||
{
|
{
|
||||||
projections.add(Projection.relativeToViewRoot(bodyBubble, bodyBubbleCorners).translateX(bodyBubble.getTranslationX()));
|
projections.add(Projection.relativeToViewRoot(bodyBubble, bodyBubbleCorners).translateX(bodyBubble.getTranslationX()));
|
||||||
|
|
|
@ -51,7 +51,7 @@ sealed class ChatColorSelectionRepository(context: Context) {
|
||||||
if (wallpaper != null) {
|
if (wallpaper != null) {
|
||||||
consumer(wallpaper.autoChatColors)
|
consumer(wallpaper.autoChatColors)
|
||||||
} else {
|
} else {
|
||||||
consumer(ChatColorsPalette.Bubbles.default)
|
consumer(ChatColorsPalette.Bubbles.default.withId(ChatColors.Id.Auto))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -30,7 +30,7 @@ data class ChatColorSelectionState(
|
||||||
)
|
)
|
||||||
} else {
|
} else {
|
||||||
ChatColorMappingModel(
|
ChatColorMappingModel(
|
||||||
ChatColorsPalette.Bubbles.default,
|
ChatColorsPalette.Bubbles.default.withId(ChatColors.Id.Auto),
|
||||||
chatColors?.id == ChatColors.Id.Auto,
|
chatColors?.id == ChatColors.Id.Auto,
|
||||||
true
|
true
|
||||||
)
|
)
|
||||||
|
|
|
@ -927,7 +927,7 @@ public class Recipient {
|
||||||
} else if (getWallpaper() != null) {
|
} else if (getWallpaper() != null) {
|
||||||
return getWallpaper().getAutoChatColors();
|
return getWallpaper().getAutoChatColors();
|
||||||
} else {
|
} else {
|
||||||
return ChatColorsPalette.Bubbles.getDefault();
|
return ChatColorsPalette.Bubbles.getDefault().withId(ChatColors.Id.Auto.INSTANCE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -116,13 +116,13 @@ public class ChatWallpaperFragment extends Fragment {
|
||||||
viewModel.saveWallpaperSelection();
|
viewModel.saveWallpaperSelection();
|
||||||
dialog.dismiss();
|
dialog.dismiss();
|
||||||
})
|
})
|
||||||
.setNeutralButton(R.string.ChatWallpaperFragment__reset_all_wallpapers, (dialog, which) -> {
|
.setNegativeButton(R.string.ChatWallpaperFragment__reset_all_wallpapers, (dialog, which) -> {
|
||||||
viewModel.setWallpaper(null);
|
viewModel.setWallpaper(null);
|
||||||
viewModel.setDimInDarkTheme(true);
|
viewModel.setDimInDarkTheme(true);
|
||||||
viewModel.resetAllWallpaper();
|
viewModel.resetAllWallpaper();
|
||||||
dialog.dismiss();
|
dialog.dismiss();
|
||||||
})
|
})
|
||||||
.setNegativeButton(android.R.string.cancel, (dialog, which) -> {
|
.setNeutralButton(android.R.string.cancel, (dialog, which) -> {
|
||||||
dialog.dismiss();
|
dialog.dismiss();
|
||||||
})
|
})
|
||||||
.show();
|
.show();
|
||||||
|
@ -136,11 +136,11 @@ public class ChatWallpaperFragment extends Fragment {
|
||||||
viewModel.clearChatColor();
|
viewModel.clearChatColor();
|
||||||
dialog.dismiss();
|
dialog.dismiss();
|
||||||
})
|
})
|
||||||
.setNeutralButton(R.string.ChatWallpaperFragment__reset_all_colors, (dialog, which) -> {
|
.setNegativeButton(R.string.ChatWallpaperFragment__reset_all_colors, (dialog, which) -> {
|
||||||
viewModel.resetAllChatColors();
|
viewModel.resetAllChatColors();
|
||||||
dialog.dismiss();
|
dialog.dismiss();
|
||||||
})
|
})
|
||||||
.setNegativeButton(android.R.string.cancel, (dialog, which) -> {
|
.setNeutralButton(android.R.string.cancel, (dialog, which) -> {
|
||||||
dialog.dismiss();
|
dialog.dismiss();
|
||||||
})
|
})
|
||||||
.show();
|
.show();
|
||||||
|
|
|
@ -44,7 +44,7 @@ class ChatWallpaperRepository {
|
||||||
} else if (SignalStore.wallpaper().hasWallpaperSet()) {
|
} else if (SignalStore.wallpaper().hasWallpaperSet()) {
|
||||||
return Objects.requireNonNull(SignalStore.wallpaper().getWallpaper()).getAutoChatColors();
|
return Objects.requireNonNull(SignalStore.wallpaper().getWallpaper()).getAutoChatColors();
|
||||||
} else {
|
} else {
|
||||||
return ChatColorsPalette.Bubbles.getDefault();
|
return ChatColorsPalette.Bubbles.getDefault().withId(ChatColors.Id.Auto.INSTANCE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Ładowanie…
Reference in New Issue