Support for disappearing messages
// FREEBIE
BIN
res/drawable-hdpi/ic_hourglass_empty_white_18dp.png
Normal file
After Width: | Height: | Size: 298 B |
BIN
res/drawable-hdpi/ic_hourglass_full_white_18dp.png
Normal file
After Width: | Height: | Size: 230 B |
BIN
res/drawable-hdpi/ic_timer_off_white_24dp.png
Normal file
After Width: | Height: | Size: 555 B |
BIN
res/drawable-hdpi/ic_timer_white_24dp.png
Normal file
After Width: | Height: | Size: 499 B |
BIN
res/drawable-mdpi/ic_hourglass_empty_white_18dp.png
Normal file
After Width: | Height: | Size: 224 B |
BIN
res/drawable-mdpi/ic_hourglass_full_white_18dp.png
Normal file
After Width: | Height: | Size: 195 B |
BIN
res/drawable-mdpi/ic_timer_off_white_24dp.png
Normal file
After Width: | Height: | Size: 361 B |
BIN
res/drawable-mdpi/ic_timer_white_24dp.png
Normal file
After Width: | Height: | Size: 329 B |
BIN
res/drawable-xhdpi/ic_hourglass_empty_white_18dp.png
Normal file
After Width: | Height: | Size: 273 B |
BIN
res/drawable-xhdpi/ic_hourglass_full_white_18dp.png
Normal file
After Width: | Height: | Size: 197 B |
BIN
res/drawable-xhdpi/ic_timer_off_white_24dp.png
Normal file
After Width: | Height: | Size: 641 B |
BIN
res/drawable-xhdpi/ic_timer_white_24dp.png
Normal file
After Width: | Height: | Size: 628 B |
BIN
res/drawable-xxhdpi/ic_hourglass_empty_white_18dp.png
Normal file
After Width: | Height: | Size: 509 B |
BIN
res/drawable-xxhdpi/ic_hourglass_full_white_18dp.png
Normal file
After Width: | Height: | Size: 349 B |
BIN
res/drawable-xxhdpi/ic_timer_off_white_24dp.png
Normal file
After Width: | Height: | Size: 986 B |
BIN
res/drawable-xxhdpi/ic_timer_white_24dp.png
Normal file
After Width: | Height: | Size: 901 B |
BIN
res/drawable-xxxhdpi/ic_hourglass_empty_white_18dp.png
Normal file
After Width: | Height: | Size: 417 B |
BIN
res/drawable-xxxhdpi/ic_hourglass_full_white_18dp.png
Normal file
After Width: | Height: | Size: 279 B |
BIN
res/drawable-xxxhdpi/ic_timer_off_white_24dp.png
Normal file
After Width: | Height: | Size: 1.3 KiB |
BIN
res/drawable-xxxhdpi/ic_timer_white_24dp.png
Normal file
After Width: | Height: | Size: 1.2 KiB |
@@ -46,7 +46,8 @@
|
||||
android:layout_toRightOf="@id/contact_photo"
|
||||
android:layout_marginRight="35dp"
|
||||
android:background="@drawable/received_bubble"
|
||||
android:orientation="vertical">
|
||||
android:orientation="vertical"
|
||||
tools:backgroundTint="@color/blue_900">
|
||||
|
||||
<org.thoughtcrime.securesms.components.ThumbnailView
|
||||
android:id="@+id/image_view"
|
||||
@@ -115,14 +116,28 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:paddingTop="2dp"
|
||||
android:paddingRight="4dp"
|
||||
android:paddingRight="2dp"
|
||||
android:paddingEnd="4dp"
|
||||
android:src="?menu_lock_icon_small"
|
||||
android:contentDescription="@string/conversation_item__secure_message_description"
|
||||
android:visibility="gone"
|
||||
android:tint="?conversation_item_received_text_secondary_color"
|
||||
android:tintMode="multiply"/>
|
||||
android:tintMode="multiply"
|
||||
tools:visibility="visible"/>
|
||||
|
||||
<org.thoughtcrime.securesms.components.ExpirationTimerView
|
||||
android:id="@+id/expiration_indicator"
|
||||
app:empty="@drawable/ic_hourglass_empty_white_18dp"
|
||||
app:full="@drawable/ic_hourglass_full_white_18dp"
|
||||
app:tint="?conversation_item_received_text_secondary_color"
|
||||
app:percentage="0"
|
||||
app:offset="0"
|
||||
android:layout_gravity="center_vertical|end"
|
||||
android:alpha=".65"
|
||||
android:layout_width="10dp"
|
||||
android:layout_height="11dp"
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible"/>
|
||||
|
||||
<org.thoughtcrime.securesms.components.DeliveryStatusView
|
||||
android:id="@+id/delivery_status"
|
||||
@@ -141,7 +156,8 @@
|
||||
android:fontFamily="sans-serif-light"
|
||||
android:autoLink="none"
|
||||
android:linksClickable="false"
|
||||
tools:text="Now"/>
|
||||
tools:text="Now"
|
||||
tools:visibility="visible"/>
|
||||
|
||||
<TextView android:id="@+id/sim_info"
|
||||
android:layout_width="wrap_content"
|
||||
|
@@ -120,7 +120,7 @@
|
||||
android:minWidth="15sp"
|
||||
android:linksClickable="false"
|
||||
android:textAppearance="?android:attr/textAppearanceSmall"
|
||||
android:layout_gravity="right"
|
||||
android:layout_gravity="right|bottom"
|
||||
android:fontFamily="sans-serif-light"
|
||||
android:textColor="?conversation_item_sent_text_secondary_color"
|
||||
android:textSize="@dimen/conversation_item_date_text_size"
|
||||
@@ -135,7 +135,7 @@
|
||||
android:minWidth="15sp"
|
||||
android:linksClickable="false"
|
||||
android:textAppearance="?android:attr/textAppearanceSmall"
|
||||
android:layout_gravity="right"
|
||||
android:layout_gravity="right|bottom"
|
||||
android:fontFamily="sans-serif-light"
|
||||
android:textColor="?conversation_item_sent_text_secondary_color"
|
||||
android:textSize="@dimen/conversation_item_date_text_size"
|
||||
@@ -151,8 +151,24 @@
|
||||
android:id="@+id/delivery_status"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:alpha=".7"
|
||||
app:iconColor="?conversation_item_sent_text_secondary_color"/>
|
||||
|
||||
<org.thoughtcrime.securesms.components.ExpirationTimerView
|
||||
android:id="@+id/expiration_indicator"
|
||||
app:empty="@drawable/ic_hourglass_empty_white_18dp"
|
||||
app:full="@drawable/ic_hourglass_full_white_18dp"
|
||||
app:tint="@color/black"
|
||||
app:percentage="0"
|
||||
app:offset="0"
|
||||
android:layout_gravity="center_vertical|end"
|
||||
android:alpha=".6"
|
||||
android:layout_marginLeft="3dp"
|
||||
android:layout_width="10dp"
|
||||
android:layout_height="11dp"
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible"/>
|
||||
|
||||
<ImageView android:id="@+id/secure_indicator"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -160,10 +176,10 @@
|
||||
android:visibility="gone"
|
||||
android:layout_gravity="center_vertical|end"
|
||||
android:paddingLeft="2dp"
|
||||
android:paddingBottom="3dp"
|
||||
android:tint="?conversation_item_sent_text_secondary_color"
|
||||
android:tintMode="multiply"
|
||||
android:contentDescription="@string/conversation_item__secure_message_description" />
|
||||
android:contentDescription="@string/conversation_item__secure_message_description"
|
||||
tools:visibility="visible"/>
|
||||
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
@@ -5,6 +5,8 @@
|
||||
android:id="@+id/conversation_update_item"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:focusable="true"
|
||||
android:background="@drawable/conversation_item_background"
|
||||
android:orientation="horizontal"
|
||||
android:gravity="center"
|
||||
android:padding="20dp">
|
||||
|
@@ -1,10 +1,12 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<merge xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<merge xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<FrameLayout android:id="@+id/pending_indicator_stub"
|
||||
android:layout_width="wrap_content"
|
||||
android:paddingRight="2dp"
|
||||
android:layout_height="wrap_content" />
|
||||
android:layout_height="wrap_content"
|
||||
tools:visibility="gone"/>
|
||||
|
||||
<ImageView android:id="@+id/sent_indicator"
|
||||
android:layout_width="wrap_content"
|
||||
@@ -24,6 +26,7 @@
|
||||
android:paddingLeft="2dp"
|
||||
android:paddingBottom="2dp"
|
||||
android:visibility="gone"
|
||||
android:contentDescription="@string/conversation_item_sent__delivered_description" />
|
||||
android:contentDescription="@string/conversation_item_sent__delivered_description"
|
||||
tools:visibility="visible"/>
|
||||
|
||||
</merge>
|
31
res/layout/expiration_dialog.xml
Normal file
@@ -0,0 +1,31 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:orientation="vertical"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:gravity="center">
|
||||
|
||||
<cn.carbswang.android.numberpickerview.library.NumberPickerView
|
||||
android:id="@+id/expiration_number_picker"
|
||||
android:layout_alignParentTop="true"
|
||||
app:npv_WrapSelectorWheel="false"
|
||||
app:npv_DividerColor="#cbc8ea"
|
||||
app:npv_TextColorSelected="@color/black"
|
||||
app:npv_ItemPaddingVertical="20dp"
|
||||
app:npv_TextColorHint="@color/grey_600"
|
||||
app:npv_TextSizeNormal="16sp"
|
||||
app:npv_TextSizeSelected="16sp"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"/>
|
||||
|
||||
<TextView android:id="@+id/expiration_details"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@id/expiration_number_picker"
|
||||
android:minLines="2"
|
||||
android:padding="20dp"/>
|
||||
|
||||
|
||||
</RelativeLayout>
|
26
res/layout/expiration_timer_menu.xml
Normal file
@@ -0,0 +1,26 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
style="?android:attr/actionButtonStyle"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:clickable="true"
|
||||
android:focusable="true"
|
||||
android:gravity="center">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/menu_badge_icon"
|
||||
android:src="@drawable/ic_timer_white_24dp"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/expiration_badge"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="bottom|center_horizontal"
|
||||
android:gravity="center_horizontal|bottom"
|
||||
android:paddingBottom="3dp"
|
||||
android:paddingTop="1dp"
|
||||
android:textColor="@android:color/white"
|
||||
android:textSize="10sp" />
|
||||
</FrameLayout>
|
@@ -75,6 +75,26 @@
|
||||
|
||||
</TableRow>
|
||||
|
||||
<TableRow android:id="@+id/expires_container"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="@dimen/message_details_table_row_pad"
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible">
|
||||
|
||||
<TextView android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="Disappears"
|
||||
android:textStyle="bold"/>
|
||||
|
||||
<TextView android:id="@+id/expires_in"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="@dimen/message_details_table_row_pad"
|
||||
tools:text="1 week"/>
|
||||
|
||||
</TableRow>
|
||||
|
||||
<TableRow android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="@dimen/message_details_table_row_pad">
|
||||
|
@@ -4,6 +4,6 @@
|
||||
<item android:title="@string/conversation_callable_insecure__menu_call"
|
||||
android:id="@+id/menu_call_insecure"
|
||||
android:icon="?menu_call_icon"
|
||||
app:showAsAction="ifRoom" />
|
||||
app:showAsAction="always" />
|
||||
|
||||
</menu>
|
||||
|
@@ -5,6 +5,6 @@
|
||||
<item android:title="@string/conversation_callable_secure__menu_call"
|
||||
android:id="@+id/menu_call_secure"
|
||||
android:icon="@drawable/ic_call_secure_white_24dp"
|
||||
app:showAsAction="ifRoom" />
|
||||
app:showAsAction="always" />
|
||||
|
||||
</menu>
|
9
res/menu/conversation_expiring_off.xml
Normal file
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<menu xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||
|
||||
<item android:title="@string/conversation_expiring_off__disappearing_messages"
|
||||
android:id="@+id/menu_expiring_messages_off"
|
||||
android:icon="@drawable/ic_timer_off_white_24dp"/>
|
||||
|
||||
</menu>
|
10
res/menu/conversation_expiring_on.xml
Normal file
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<menu xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||
|
||||
<item android:id="@+id/menu_expiring_messages"
|
||||
app:actionLayout="@layout/expiration_timer_menu"
|
||||
app:showAsAction="always"
|
||||
android:title="@string/menu_conversation_expiring_on__messages_expiring"/>
|
||||
|
||||
</menu>
|
@@ -238,4 +238,19 @@
|
||||
<item>@null</item>
|
||||
</array>
|
||||
|
||||
<integer-array name="expiration_times">
|
||||
<item>0</item>
|
||||
<item>5</item>
|
||||
<item>10</item>
|
||||
<item>30</item>
|
||||
<item>60</item>
|
||||
<item>300</item>
|
||||
<item>1800</item>
|
||||
<item>3600</item>
|
||||
<item>21600</item>
|
||||
<item>43200</item>
|
||||
<item>86400</item>
|
||||
<item>604800</item>
|
||||
</integer-array>
|
||||
|
||||
</resources>
|
||||
|
@@ -166,4 +166,12 @@
|
||||
<attr name="camera" format="integer"/>
|
||||
</declare-styleable>
|
||||
|
||||
<declare-styleable name="HourglassView">
|
||||
<attr name="full" format="reference"/>
|
||||
<attr name="empty" format="reference"/>
|
||||
<attr name="tint" format="color"/>
|
||||
<attr name="percentage" format="integer"/>
|
||||
<attr name="offset" format="integer"/>
|
||||
</declare-styleable>
|
||||
|
||||
</resources>
|
||||
|
@@ -379,6 +379,8 @@
|
||||
<string name="MessageRecord_called_s">Called %s</string>
|
||||
<string name="MessageRecord_missed_call_from">Missed call from %s</string>
|
||||
<string name="MessageRecord_s_is_on_signal_say_hey">%s is on Signal, say hey!</string>
|
||||
<string name="MessageRecord_you">You</string>
|
||||
<string name="MessageRecord_s_set_disappearing_message_time_to_s">%1$s set disappearing message time to %2$s</string>
|
||||
|
||||
|
||||
<!-- PassphraseChangeActivity -->
|
||||
@@ -407,6 +409,11 @@
|
||||
<string name="DeviceProvisioningActivity_link_a_signal_device">Link a Signal device?</string>
|
||||
<string name="DeviceProvisioningActivity_it_looks_like_youre_trying_to_link_a_signal_device_using_a_3rd_party_scanner">It looks like you\'re trying to link a Signal device using a 3rd party scanner. For your protection, please scan the code again from within Signal.</string>
|
||||
|
||||
<!-- ExpirationDialog -->
|
||||
<string name="ExpirationDialog_disappearing_messages">Disappearing messages</string>
|
||||
<string name="ExpirationDialog_your_messages_will_not_expire">Your messages will not expire.</string>
|
||||
<string name="ExpirationDialog_your_messages_will_disappear_s_after_they_have_been_seen">Messages sent and received in this conversation will disappear %s after they have been seen.</string>
|
||||
|
||||
<!-- PassphrasePromptActivity -->
|
||||
<string name="PassphrasePromptActivity_enter_passphrase">Enter passphrase</string>
|
||||
<string name="PassphrasePromptActivity_watermark_content_description">Signal icon</string>
|
||||
@@ -537,6 +544,7 @@
|
||||
<string name="ThreadRecord_missed_call">Missed call</string>
|
||||
<string name="ThreadRecord_media_message">Media message</string>
|
||||
<string name="ThreadRecord_s_is_on_signal_say_hey">%s is on Signal, say hey!</string>
|
||||
<string name="ThreadRecord_disappearing_message_time_updated_to_s">Disappearing message time set to %s</string>
|
||||
|
||||
<!-- VerifyIdentityActivity -->
|
||||
<string name="VerifyIdentityActivity_you_do_not_have_an_identity_key">You do not have an identity key.</string>
|
||||
@@ -711,10 +719,48 @@
|
||||
<string name="device_list_fragment__no_devices_linked">No devices linked...</string>
|
||||
<string name="device_list_fragment__link_new_device">Link new device</string>
|
||||
|
||||
|
||||
<!-- experience_upgrade_activity -->
|
||||
<string name="experience_upgrade_activity__continue">continue</string>
|
||||
|
||||
<!-- expiration -->
|
||||
|
||||
<string name="expiration_off">Off</string>
|
||||
|
||||
<plurals name="expiration_seconds">
|
||||
<item quantity="one">1 second</item>
|
||||
<item quantity="other">%d seconds</item>
|
||||
</plurals>
|
||||
|
||||
<string name="expiration_seconds_abbreviated">%ds</string>
|
||||
|
||||
<plurals name="expiration_minutes">
|
||||
<item quantity="one">1 minute</item>
|
||||
<item quantity="other">%d minutes</item>
|
||||
</plurals>
|
||||
|
||||
<string name="expiration_minutes_abbreviated">%dm</string>
|
||||
|
||||
<plurals name="expiration_hours">
|
||||
<item quantity="one">1 hour</item>
|
||||
<item quantity="other">%d hours</item>
|
||||
</plurals>
|
||||
|
||||
<string name="expiration_hours_abbreviated">%dh</string>
|
||||
|
||||
<plurals name="expiration_days">
|
||||
<item quantity="one">1 day</item>
|
||||
<item quantity="other">%d days</item>
|
||||
</plurals>
|
||||
|
||||
<string name="expiration_days_abbreviated">%dd</string>
|
||||
|
||||
<plurals name="expiration_weeks">
|
||||
<item quantity="one">1 week</item>
|
||||
<item quantity="other">%d weeks</item>
|
||||
</plurals>
|
||||
|
||||
<string name="expiration_weeks_abbreviated">%dw</string>
|
||||
|
||||
<!-- log_submit_activity -->
|
||||
<string name="log_submit_activity__log_fetch_failed">Could not read the log on your device. You can still use ADB to get a debug log instead.</string>
|
||||
<string name="log_submit_activity__thanks">Thanks for your help!</string>
|
||||
@@ -1078,6 +1124,12 @@
|
||||
<!-- conversation_context_image -->
|
||||
<string name="conversation_context_image__save_attachment">Save attachment</string>
|
||||
|
||||
<!-- conversation_expiring_off -->
|
||||
<string name="conversation_expiring_off__disappearing_messages">Disappearing messages</string>
|
||||
|
||||
<!-- conversation_expiring_on -->
|
||||
<string name="menu_conversation_expiring_on__messages_expiring">Messages expiring</string>
|
||||
|
||||
<!-- conversation_insecure -->
|
||||
<string name="conversation_insecure__invite">Invite</string>
|
||||
|
||||
|