Skip to content
Snippets Groups Projects
Commit a45d09ef authored by akwizgran's avatar akwizgran
Browse files

Show whether identities are anonymous, unknown, or verified.

Dev task #52. Known but unverified identities are also supported, but
currently unused. These will be used in future for contacts who've been
introduced but not verified face to face.
parent 035fc432
No related merge requests found
Showing
with 6 additions and 9 deletions
briar-android/res/drawable-hdpi/contact_connected.png

1.4 KiB | W: | H:

briar-android/res/drawable-hdpi/contact_connected.png

1.29 KiB | W: | H:

briar-android/res/drawable-hdpi/contact_connected.png
briar-android/res/drawable-hdpi/contact_connected.png
briar-android/res/drawable-hdpi/contact_connected.png
briar-android/res/drawable-hdpi/contact_connected.png
  • 2-up
  • Swipe
  • Onion skin
briar-android/res/drawable-hdpi/contact_disconnected.png

1.4 KiB | W: | H:

briar-android/res/drawable-hdpi/contact_disconnected.png

1.11 KiB | W: | H:

briar-android/res/drawable-hdpi/contact_disconnected.png
briar-android/res/drawable-hdpi/contact_disconnected.png
briar-android/res/drawable-hdpi/contact_disconnected.png
briar-android/res/drawable-hdpi/contact_disconnected.png
  • 2-up
  • Swipe
  • Onion skin
briar-android/res/drawable-hdpi/identity_anonymous.png

975 B

briar-android/res/drawable-hdpi/identity_unknown.png

1.38 KiB

briar-android/res/drawable-hdpi/identity_unverified.png

1.4 KiB

briar-android/res/drawable-hdpi/identity_verified.png

1009 B

briar-android/res/drawable-mdpi/contact_connected.png

689 B | W: | H:

briar-android/res/drawable-mdpi/contact_connected.png

682 B | W: | H:

briar-android/res/drawable-mdpi/contact_connected.png
briar-android/res/drawable-mdpi/contact_connected.png
briar-android/res/drawable-mdpi/contact_connected.png
briar-android/res/drawable-mdpi/contact_connected.png
  • 2-up
  • Swipe
  • Onion skin
briar-android/res/drawable-mdpi/contact_disconnected.png

605 B | W: | H:

briar-android/res/drawable-mdpi/contact_disconnected.png

484 B | W: | H:

briar-android/res/drawable-mdpi/contact_disconnected.png
briar-android/res/drawable-mdpi/contact_disconnected.png
briar-android/res/drawable-mdpi/contact_disconnected.png
briar-android/res/drawable-mdpi/contact_disconnected.png
  • 2-up
  • Swipe
  • Onion skin
briar-android/res/drawable-mdpi/identity_anonymous.png

362 B

briar-android/res/drawable-mdpi/identity_unknown.png

708 B

briar-android/res/drawable-mdpi/identity_unverified.png

713 B

briar-android/res/drawable-mdpi/identity_verified.png

531 B

briar-android/res/drawable-xhdpi/contact_connected.png

1.49 KiB | W: | H:

briar-android/res/drawable-xhdpi/contact_connected.png

1.07 KiB | W: | H:

briar-android/res/drawable-xhdpi/contact_connected.png
briar-android/res/drawable-xhdpi/contact_connected.png
briar-android/res/drawable-xhdpi/contact_connected.png
briar-android/res/drawable-xhdpi/contact_connected.png
  • 2-up
  • Swipe
  • Onion skin
briar-android/res/drawable-xhdpi/contact_disconnected.png

1.38 KiB | W: | H:

briar-android/res/drawable-xhdpi/contact_disconnected.png

1.14 KiB | W: | H:

briar-android/res/drawable-xhdpi/contact_disconnected.png
briar-android/res/drawable-xhdpi/contact_disconnected.png
briar-android/res/drawable-xhdpi/contact_disconnected.png
briar-android/res/drawable-xhdpi/contact_disconnected.png
  • 2-up
  • Swipe
  • Onion skin
briar-android/res/drawable-xhdpi/identity_anonymous.png

853 B

briar-android/res/drawable-xhdpi/identity_unknown.png

1.44 KiB

briar-android/res/drawable-xhdpi/identity_unverified.png

1.53 KiB

briar-android/res/drawable-xhdpi/identity_verified.png

1.11 KiB

...@@ -4,7 +4,6 @@ ...@@ -4,7 +4,6 @@
<color name="content_background">#FFFFFF</color> <color name="content_background">#FFFFFF</color>
<color name="unread_background">#FFFFFF</color> <color name="unread_background">#FFFFFF</color>
<color name="horizontal_border">#CCCCCC</color> <color name="horizontal_border">#CCCCCC</color>
<color name="anonymous_author">#AAAAAA</color>
<color name="no_posts">#AAAAAA</color> <color name="no_posts">#AAAAAA</color>
<color name="no_messages">#AAAAAA</color> <color name="no_messages">#AAAAAA</color>
</resources> </resources>
\ No newline at end of file
...@@ -3,10 +3,12 @@ package org.briarproject.android.contact; ...@@ -3,10 +3,12 @@ package org.briarproject.android.contact;
import static android.widget.LinearLayout.HORIZONTAL; import static android.widget.LinearLayout.HORIZONTAL;
import static java.text.DateFormat.SHORT; import static java.text.DateFormat.SHORT;
import static org.briarproject.android.util.CommonLayoutParams.WRAP_WRAP_1; import static org.briarproject.android.util.CommonLayoutParams.WRAP_WRAP_1;
import static org.briarproject.api.Author.Status.VERIFIED;
import java.util.ArrayList; import java.util.ArrayList;
import org.briarproject.R; import org.briarproject.R;
import org.briarproject.android.util.AuthorView;
import org.briarproject.android.util.LayoutUtils; import org.briarproject.android.util.LayoutUtils;
import org.briarproject.api.db.MessageHeader; import org.briarproject.api.db.MessageHeader;
...@@ -41,14 +43,10 @@ class ConversationAdapter extends ArrayAdapter<ConversationItem> { ...@@ -41,14 +43,10 @@ class ConversationAdapter extends ArrayAdapter<ConversationItem> {
layout.setBackgroundColor(res.getColor(R.color.unread_background)); layout.setBackgroundColor(res.getColor(R.color.unread_background));
} }
TextView name = new TextView(ctx); AuthorView authorView = new AuthorView(ctx);
// Give me all the unused width authorView.setLayoutParams(WRAP_WRAP_1);
name.setLayoutParams(WRAP_WRAP_1); authorView.init(header.getAuthor().getName(), VERIFIED);
name.setTextSize(18); layout.addView(authorView);
name.setMaxLines(1);
name.setPadding(pad, pad, pad, pad);
name.setText(header.getAuthor().getName());
layout.addView(name);
TextView date = new TextView(ctx); TextView date = new TextView(ctx);
date.setTextSize(14); date.setTextSize(14);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment