aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/main/java/eu/siacs/conversations/ui/adapter/MessageAdapter.java33
-rw-r--r--src/main/res/drawable-hdpi/ic_lock_black_18dp.pngbin368 -> 275 bytes
-rw-r--r--src/main/res/drawable-hdpi/ic_lock_white_18dp.pngbin371 -> 281 bytes
-rw-r--r--src/main/res/drawable-hdpi/ic_verified_user_black_18dp.pngbin0 -> 320 bytes
-rw-r--r--src/main/res/drawable-hdpi/ic_verified_user_white_18dp.pngbin0 -> 329 bytes
-rw-r--r--src/main/res/drawable-mdpi/ic_lock_black_18dp.pngbin293 -> 206 bytes
-rw-r--r--src/main/res/drawable-mdpi/ic_lock_white_18dp.pngbin298 -> 211 bytes
-rw-r--r--src/main/res/drawable-mdpi/ic_verified_user_black_18dp.pngbin0 -> 238 bytes
-rw-r--r--src/main/res/drawable-mdpi/ic_verified_user_white_18dp.pngbin0 -> 241 bytes
-rw-r--r--src/main/res/drawable-xhdpi/ic_lock_black_18dp.pngbin397 -> 308 bytes
-rw-r--r--src/main/res/drawable-xhdpi/ic_lock_white_18dp.pngbin399 -> 309 bytes
-rw-r--r--src/main/res/drawable-xhdpi/ic_verified_user_black_18dp.pngbin0 -> 390 bytes
-rw-r--r--src/main/res/drawable-xhdpi/ic_verified_user_white_18dp.pngbin0 -> 407 bytes
-rw-r--r--src/main/res/drawable-xxhdpi/ic_lock_black_18dp.pngbin559 -> 453 bytes
-rw-r--r--src/main/res/drawable-xxhdpi/ic_lock_white_18dp.pngbin558 -> 463 bytes
-rw-r--r--src/main/res/drawable-xxhdpi/ic_verified_user_black_18dp.pngbin0 -> 516 bytes
-rw-r--r--src/main/res/drawable-xxhdpi/ic_verified_user_white_18dp.pngbin0 -> 538 bytes
-rw-r--r--src/main/res/drawable-xxxhdpi/ic_lock_black_18dp.pngbin636 -> 527 bytes
-rw-r--r--src/main/res/drawable-xxxhdpi/ic_lock_white_18dp.pngbin760 -> 540 bytes
-rw-r--r--src/main/res/drawable-xxxhdpi/ic_verified_user_black_18dp.pngbin0 -> 634 bytes
-rw-r--r--src/main/res/drawable-xxxhdpi/ic_verified_user_white_18dp.pngbin0 -> 668 bytes
21 files changed, 13 insertions, 20 deletions
diff --git a/src/main/java/eu/siacs/conversations/ui/adapter/MessageAdapter.java b/src/main/java/eu/siacs/conversations/ui/adapter/MessageAdapter.java
index 66c60ca5..d09c70ea 100644
--- a/src/main/java/eu/siacs/conversations/ui/adapter/MessageAdapter.java
+++ b/src/main/java/eu/siacs/conversations/ui/adapter/MessageAdapter.java
@@ -211,31 +211,24 @@ public class MessageAdapter extends ArrayAdapter<Message> implements CopyTextVie
if (message.getEncryption() == Message.ENCRYPTION_NONE) {
viewHolder.indicator.setVisibility(View.GONE);
} else {
- viewHolder.indicator.setImageResource(darkBackground ? R.drawable.ic_lock_white_18dp : R.drawable.ic_lock_black_18dp);
- viewHolder.indicator.setVisibility(View.VISIBLE);
+ boolean verified = false;
if (message.getEncryption() == Message.ENCRYPTION_AXOLOTL) {
- FingerprintStatus status = message.getConversation()
+ final FingerprintStatus status = message.getConversation()
.getAccount().getAxolotlService().getFingerprintTrust(
message.getFingerprint());
-
- if(status == null || (type == SENT ? !status.isTrusted() : (!status.isVerified() && inValidSession))) {
- viewHolder.indicator.setColorFilter(0xffc64545);
- viewHolder.indicator.setAlpha(1.0f);
- } else {
- viewHolder.indicator.clearColorFilter();
- if (darkBackground) {
- viewHolder.indicator.setAlpha(0.7f);
- } else {
- viewHolder.indicator.setAlpha(0.57f);
- }
+ if (status != null && status.isVerified()) {
+ verified = true;
}
+ }
+ if (verified) {
+ viewHolder.indicator.setImageResource(darkBackground ? R.drawable.ic_verified_user_white_18dp : R.drawable.ic_verified_user_black_18dp);
} else {
- viewHolder.indicator.clearColorFilter();
- if (darkBackground) {
- viewHolder.indicator.setAlpha(0.7f);
- } else {
- viewHolder.indicator.setAlpha(0.57f);
- }
+ viewHolder.indicator.setImageResource(darkBackground ? R.drawable.ic_lock_white_18dp : R.drawable.ic_lock_black_18dp);
+ }
+ if (darkBackground) {
+ viewHolder.indicator.setAlpha(0.7f);
+ } else {
+ viewHolder.indicator.setAlpha(0.57f);
}
}
diff --git a/src/main/res/drawable-hdpi/ic_lock_black_18dp.png b/src/main/res/drawable-hdpi/ic_lock_black_18dp.png
index 4c7a7c59..f3142927 100644
--- a/src/main/res/drawable-hdpi/ic_lock_black_18dp.png
+++ b/src/main/res/drawable-hdpi/ic_lock_black_18dp.png
Binary files differ
diff --git a/src/main/res/drawable-hdpi/ic_lock_white_18dp.png b/src/main/res/drawable-hdpi/ic_lock_white_18dp.png
index 29e8bfd3..f5f86141 100644
--- a/src/main/res/drawable-hdpi/ic_lock_white_18dp.png
+++ b/src/main/res/drawable-hdpi/ic_lock_white_18dp.png
Binary files differ
diff --git a/src/main/res/drawable-hdpi/ic_verified_user_black_18dp.png b/src/main/res/drawable-hdpi/ic_verified_user_black_18dp.png
new file mode 100644
index 00000000..48e38bf9
--- /dev/null
+++ b/src/main/res/drawable-hdpi/ic_verified_user_black_18dp.png
Binary files differ
diff --git a/src/main/res/drawable-hdpi/ic_verified_user_white_18dp.png b/src/main/res/drawable-hdpi/ic_verified_user_white_18dp.png
new file mode 100644
index 00000000..1e252c0d
--- /dev/null
+++ b/src/main/res/drawable-hdpi/ic_verified_user_white_18dp.png
Binary files differ
diff --git a/src/main/res/drawable-mdpi/ic_lock_black_18dp.png b/src/main/res/drawable-mdpi/ic_lock_black_18dp.png
index c8b6fe71..317c034b 100644
--- a/src/main/res/drawable-mdpi/ic_lock_black_18dp.png
+++ b/src/main/res/drawable-mdpi/ic_lock_black_18dp.png
Binary files differ
diff --git a/src/main/res/drawable-mdpi/ic_lock_white_18dp.png b/src/main/res/drawable-mdpi/ic_lock_white_18dp.png
index 1265e98e..b9666133 100644
--- a/src/main/res/drawable-mdpi/ic_lock_white_18dp.png
+++ b/src/main/res/drawable-mdpi/ic_lock_white_18dp.png
Binary files differ
diff --git a/src/main/res/drawable-mdpi/ic_verified_user_black_18dp.png b/src/main/res/drawable-mdpi/ic_verified_user_black_18dp.png
new file mode 100644
index 00000000..59964fb0
--- /dev/null
+++ b/src/main/res/drawable-mdpi/ic_verified_user_black_18dp.png
Binary files differ
diff --git a/src/main/res/drawable-mdpi/ic_verified_user_white_18dp.png b/src/main/res/drawable-mdpi/ic_verified_user_white_18dp.png
new file mode 100644
index 00000000..81f1f41f
--- /dev/null
+++ b/src/main/res/drawable-mdpi/ic_verified_user_white_18dp.png
Binary files differ
diff --git a/src/main/res/drawable-xhdpi/ic_lock_black_18dp.png b/src/main/res/drawable-xhdpi/ic_lock_black_18dp.png
index 0888c617..de502959 100644
--- a/src/main/res/drawable-xhdpi/ic_lock_black_18dp.png
+++ b/src/main/res/drawable-xhdpi/ic_lock_black_18dp.png
Binary files differ
diff --git a/src/main/res/drawable-xhdpi/ic_lock_white_18dp.png b/src/main/res/drawable-xhdpi/ic_lock_white_18dp.png
index b94735ec..cd4f04aa 100644
--- a/src/main/res/drawable-xhdpi/ic_lock_white_18dp.png
+++ b/src/main/res/drawable-xhdpi/ic_lock_white_18dp.png
Binary files differ
diff --git a/src/main/res/drawable-xhdpi/ic_verified_user_black_18dp.png b/src/main/res/drawable-xhdpi/ic_verified_user_black_18dp.png
new file mode 100644
index 00000000..8ebb6db3
--- /dev/null
+++ b/src/main/res/drawable-xhdpi/ic_verified_user_black_18dp.png
Binary files differ
diff --git a/src/main/res/drawable-xhdpi/ic_verified_user_white_18dp.png b/src/main/res/drawable-xhdpi/ic_verified_user_white_18dp.png
new file mode 100644
index 00000000..3e3792f8
--- /dev/null
+++ b/src/main/res/drawable-xhdpi/ic_verified_user_white_18dp.png
Binary files differ
diff --git a/src/main/res/drawable-xxhdpi/ic_lock_black_18dp.png b/src/main/res/drawable-xxhdpi/ic_lock_black_18dp.png
index dbcf3f33..17e81589 100644
--- a/src/main/res/drawable-xxhdpi/ic_lock_black_18dp.png
+++ b/src/main/res/drawable-xxhdpi/ic_lock_black_18dp.png
Binary files differ
diff --git a/src/main/res/drawable-xxhdpi/ic_lock_white_18dp.png b/src/main/res/drawable-xxhdpi/ic_lock_white_18dp.png
index 895aabbf..47bd6411 100644
--- a/src/main/res/drawable-xxhdpi/ic_lock_white_18dp.png
+++ b/src/main/res/drawable-xxhdpi/ic_lock_white_18dp.png
Binary files differ
diff --git a/src/main/res/drawable-xxhdpi/ic_verified_user_black_18dp.png b/src/main/res/drawable-xxhdpi/ic_verified_user_black_18dp.png
new file mode 100644
index 00000000..1244f932
--- /dev/null
+++ b/src/main/res/drawable-xxhdpi/ic_verified_user_black_18dp.png
Binary files differ
diff --git a/src/main/res/drawable-xxhdpi/ic_verified_user_white_18dp.png b/src/main/res/drawable-xxhdpi/ic_verified_user_white_18dp.png
new file mode 100644
index 00000000..ea938a6e
--- /dev/null
+++ b/src/main/res/drawable-xxhdpi/ic_verified_user_white_18dp.png
Binary files differ
diff --git a/src/main/res/drawable-xxxhdpi/ic_lock_black_18dp.png b/src/main/res/drawable-xxxhdpi/ic_lock_black_18dp.png
index c49d420e..a7caa2db 100644
--- a/src/main/res/drawable-xxxhdpi/ic_lock_black_18dp.png
+++ b/src/main/res/drawable-xxxhdpi/ic_lock_black_18dp.png
Binary files differ
diff --git a/src/main/res/drawable-xxxhdpi/ic_lock_white_18dp.png b/src/main/res/drawable-xxxhdpi/ic_lock_white_18dp.png
index 0dcada81..0e52c7c7 100644
--- a/src/main/res/drawable-xxxhdpi/ic_lock_white_18dp.png
+++ b/src/main/res/drawable-xxxhdpi/ic_lock_white_18dp.png
Binary files differ
diff --git a/src/main/res/drawable-xxxhdpi/ic_verified_user_black_18dp.png b/src/main/res/drawable-xxxhdpi/ic_verified_user_black_18dp.png
new file mode 100644
index 00000000..70a9fc1b
--- /dev/null
+++ b/src/main/res/drawable-xxxhdpi/ic_verified_user_black_18dp.png
Binary files differ
diff --git a/src/main/res/drawable-xxxhdpi/ic_verified_user_white_18dp.png b/src/main/res/drawable-xxxhdpi/ic_verified_user_white_18dp.png
new file mode 100644
index 00000000..ec35ec7a
--- /dev/null
+++ b/src/main/res/drawable-xxxhdpi/ic_verified_user_white_18dp.png
Binary files differ