mirror of
https://github.com/oxen-io/session-android.git
synced 2025-12-14 09:50:06 +00:00
Add Swipe-To-Reply in conversations.
Swipe-To-Reply is a progress based animation that is controlled by the ConversationItemSwipeCallback. We use the TouchListener to keep track of the latest down coordinates, so that we can check whether we are over a seek bar. The SwipeAnimationHelper is responsible for actually performing the transitions as the swipe progresses.
This commit is contained in:
committed by
Greyson Parrelli
parent
582028f2c2
commit
007ea43dc8
@@ -23,6 +23,17 @@
|
||||
android:clipToPadding="false"
|
||||
android:clipChildren="false">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/reply_icon"
|
||||
android:layout_width="@dimen/conversation_item_reply_size"
|
||||
android:layout_height="@dimen/conversation_item_reply_size"
|
||||
android:src="@drawable/ic_reply_white_24dp"
|
||||
android:tint="?compose_icon_tint"
|
||||
android:alpha="0"
|
||||
android:layout_alignTop="@id/body_bubble"
|
||||
android:layout_alignBottom="@id/body_bubble"
|
||||
android:layout_alignStart="@id/body_bubble" />
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/contact_photo_container"
|
||||
android:layout_width="36dp"
|
||||
@@ -40,7 +51,7 @@
|
||||
|
||||
</FrameLayout>
|
||||
|
||||
<LinearLayout
|
||||
<org.thoughtcrime.securesms.conversation.ConversationItemBodyBubble
|
||||
android:id="@+id/body_bubble"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -206,7 +217,7 @@
|
||||
app:footer_text_color="?conversation_sticker_footer_text_color"
|
||||
app:footer_icon_color="?conversation_sticker_footer_icon_color"/>
|
||||
|
||||
</LinearLayout>
|
||||
</org.thoughtcrime.securesms.conversation.ConversationItemBodyBubble>
|
||||
|
||||
<org.thoughtcrime.securesms.components.AlertView
|
||||
android:id="@+id/indicators_parent"
|
||||
|
||||
@@ -22,7 +22,18 @@
|
||||
android:clipToPadding="false"
|
||||
android:clipChildren="false">
|
||||
|
||||
<LinearLayout
|
||||
<ImageView
|
||||
android:id="@+id/reply_icon"
|
||||
android:layout_width="@dimen/conversation_item_reply_size"
|
||||
android:layout_height="@dimen/conversation_item_reply_size"
|
||||
android:alpha="0"
|
||||
android:src="@drawable/ic_reply_white_24dp"
|
||||
android:tint="?compose_icon_tint"
|
||||
android:layout_alignTop="@id/body_bubble"
|
||||
android:layout_alignBottom="@id/body_bubble"
|
||||
android:layout_alignStart="@id/body_bubble" />
|
||||
|
||||
<org.thoughtcrime.securesms.conversation.ConversationItemBodyBubble
|
||||
android:id="@+id/body_bubble"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -164,7 +175,7 @@
|
||||
app:footer_text_color="?conversation_sticker_footer_text_color"
|
||||
app:footer_icon_color="?conversation_sticker_footer_icon_color"/>
|
||||
|
||||
</LinearLayout>
|
||||
</org.thoughtcrime.securesms.conversation.ConversationItemBodyBubble>
|
||||
|
||||
<org.thoughtcrime.securesms.components.AlertView
|
||||
android:id="@+id/indicators_parent"
|
||||
|
||||
@@ -64,6 +64,7 @@
|
||||
<dimen name="conversation_vertical_message_spacing_default">8dp</dimen>
|
||||
<dimen name="conversation_vertical_message_spacing_collapse">1dp</dimen>
|
||||
|
||||
<dimen name="conversation_item_reply_size">20dp</dimen>
|
||||
<dimen name="conversation_item_avatar_size">36dp</dimen>
|
||||
|
||||
<dimen name="quote_corner_radius_large">10dp</dimen>
|
||||
|
||||
Reference in New Issue
Block a user