Audio view and message bubbles properly themed.

This commit is contained in:
Anton Chekulaev
2020-08-24 18:38:48 +10:00
parent afe90200f1
commit 5e5b88148d
17 changed files with 63 additions and 33 deletions

View File

@@ -10,6 +10,7 @@ import android.widget.LinearLayout;
import org.thoughtcrime.securesms.mms.GlideRequests;
import org.thoughtcrime.securesms.recipients.Recipient;
import org.thoughtcrime.securesms.util.ThemeUtil;
import java.util.List;
@@ -41,7 +42,10 @@ public class ConversationTypingView extends LinearLayout {
}
Recipient typist = typists.get(0);
bubble.getBackground().setColorFilter(getResources().getColor(R.color.received_message_background), PorterDuff.Mode.MULTIPLY);
bubble.getBackground().setColorFilter(
ThemeUtil.getThemedColor(getContext(), R.attr.message_received_background_color),
PorterDuff.Mode.MULTIPLY);
if (isGroupThread) {
avatar.setAvatar(glideRequests, typist, false);

View File

@@ -210,7 +210,8 @@ public class QuoteView extends FrameLayout implements RecipientModifiedListener
// We use the raw color resource because Android 4.x was struggling with tints here
quoteBarView.setImageResource(R.color.accent);
mainView.setBackgroundColor(getResources().getColor(outgoing ? R.color.received_message_background : R.color.sent_message_background));
mainView.setBackgroundColor(ThemeUtil.getThemedColor(getContext(),
outgoing ? R.attr.message_received_background_color : R.attr.message_sent_background_color));
}
private void setQuoteText(@Nullable String body, @NonNull SlideDeck attachments) {