Support for sealed sender - Part 2

This commit is contained in:
Greyson Parrelli
2018-10-11 16:45:22 -07:00
parent 5f31762220
commit 2acab563d9
51 changed files with 819 additions and 394 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 478 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 311 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 490 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 765 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 988 B

View File

@@ -20,17 +20,39 @@
android:paddingLeft="10dp"
android:paddingRight="10dp">
<TextView android:id="@+id/error_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:visibility="gone"
android:textSize="16sp"
android:padding="5dp"
tools:visibility="visible"
android:text="@string/message_details_header__issues_need_your_attention"
android:drawableLeft="@drawable/ic_info_outline_light"
android:drawableStart="@drawable/ic_info_outline_light"
android:gravity="center_vertical" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<TextView android:id="@+id/error_text"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:visibility="gone"
android:textSize="16sp"
android:padding="5dp"
tools:visibility="visible"
android:text="@string/message_details_header__issues_need_your_attention"
android:drawableLeft="@drawable/ic_info_outline_light"
android:drawableStart="@drawable/ic_info_outline_light"
android:gravity="center_vertical" />
<Button
android:id="@+id/resend_button"
android:layout_width="wrap_content"
android:layout_height="38sp"
style="@style/InfoButton"
android:paddingLeft="10dp"
android:paddingRight="10dp"
android:paddingTop="5dp"
android:paddingBottom="5dp"
android:layout_gravity="center_vertical"
android:drawableLeft="@drawable/ic_refresh_white_18dp"
android:text="@string/message_recipients_list_item__resend"
android:visibility="gone"
tools:visibility="visible" />
</LinearLayout>
<TableLayout android:id="@+id/metadata_container"
android:layout_width="match_parent"

View File

@@ -80,19 +80,13 @@
android:visibility="gone"
tools:visibility="gone" />
<Button android:id="@+id/resend_button"
android:layout_width="wrap_content"
android:layout_height="38sp"
style="@style/InfoButton"
android:paddingLeft="10dp"
android:paddingRight="5dp"
android:paddingTop="5dp"
android:paddingBottom="5dp"
android:layout_gravity="center_vertical"
android:drawableLeft="@drawable/ic_refresh_white_18dp"
android:text="@string/message_recipients_list_item__resend"
android:visibility="gone"
tools:visibility="gone" />
<ImageView android:id="@+id/ud_indicator"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="4dp"
android:layout_marginRight="4dp"
android:src="@drawable/ic_unidentified_delivery"
android:tint="?attr/conversation_item_sent_text_secondary_color"/>
<org.thoughtcrime.securesms.components.DeliveryStatusView
android:id="@+id/delivery_status"

View File

@@ -0,0 +1,25 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="horizontal"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_vertical"
android:padding="16dp">
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginRight="16dp"
android:layout_marginEnd="16dp"
android:src="@drawable/ic_unidentified_delivery"
android:tint="?conversation_item_sent_text_secondary_color"/>
<TextView
android:id="@+id/ud_learn_more"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/preferences_communication__sealed_sender_learn_more"
android:textColor="@color/signal_primary"/>
</LinearLayout>

View File

@@ -86,6 +86,9 @@
<string name="ClearProfileActivity_remove">Remove</string>
<string name="ClearProfileActivity_remove_profile_photo">Remove profile photo?</string>
<!-- CommunicationActions -->
<string name="CommunicationActions_no_browser_found">No web browser found.</string>
<!-- ConfirmIdentityDialog -->
<string name="ConfirmIdentityDialog_your_safety_number_with_s_has_changed">Your safety number with %1$s has changed. This could either mean that someone is trying to intercept your communication, or that %2$s simply reinstalled Signal.</string>
<string name="ConfirmIdentityDialog_you_may_wish_to_verify_your_safety_number_with_this_contact">You may wish to verify your safety number with this contact.</string>
@@ -1204,6 +1207,12 @@
<string name="preferences_chats__message_text_size">Message font size</string>
<string name="preferences_events__contact_joined_signal">Contact joined Signal</string>
<string name="preferences_notifications__priority">Priority</string>
<string name="preferences_communication__category_sealed_sender">Sealed Sender</string>
<string name="preferences_communication__sealed_sender_display_indicators">Display indicators</string>
<string name="preferences_communication__sealed_sender_display_indicators_description">Show a status icon when you select "Message details" on messages that were delivered using sealed sender.</string>
<string name="preferences_communication__sealed_sender_allow_from_anyone">Allow from anyone</string>
<string name="preferences_communication__sealed_sender_allow_from_anyone_description">Enable sealed sender for incoming messages from non-contacts and people with whom you have not shared your profile.</string>
<string name="preferences_communication__sealed_sender_learn_more">Learn more</string>
<!-- **************************************** -->
<!-- menus -->

View File

@@ -69,6 +69,27 @@
<PreferenceCategory android:layout="@layout/preference_divider"/>
<PreferenceCategory android:title="@string/preferences_communication__category_sealed_sender">
<org.thoughtcrime.securesms.components.SwitchPreferenceCompat
android:defaultValue="false"
android:key="pref_show_unidentifed_delivery_indicators"
android:title="@string/preferences_communication__sealed_sender_display_indicators"
android:summary="@string/preferences_communication__sealed_sender_display_indicators_description"/>
<org.thoughtcrime.securesms.components.SwitchPreferenceCompat
android:defaultValue="false"
android:key="pref_universal_unidentified_access"
android:title="@string/preferences_communication__sealed_sender_allow_from_anyone"
android:summary="@string/preferences_communication__sealed_sender_allow_from_anyone_description"/>
<Preference
android:key="pref_unidentified_learn_more"
android:layout="@layout/unidentified_delivery_learn_more" />
</PreferenceCategory>
<PreferenceCategory android:layout="@layout/preference_divider"/>
<PreferenceCategory android:title="@string/preferences_app_protection__registration_lock">
<org.thoughtcrime.securesms.components.SwitchPreferenceCompat
android:defaultValue="false"