mirror of
https://gitlab.linphone.org/BC/public/linphone-android.git
synced 2026-01-17 11:28:06 +00:00
Updated margins on chat bubble
This commit is contained in:
parent
46ae326781
commit
b4a52e244d
7 changed files with 15 additions and 8 deletions
|
|
@ -466,6 +466,14 @@ fun setConstraintLayoutTopMargin(view: View, margins: Float) {
|
|||
view.layoutParams = params
|
||||
}
|
||||
|
||||
@BindingAdapter("android:layout_marginStart")
|
||||
fun setConstraintLayoutStartMargin(view: View, margins: Float) {
|
||||
val params = view.layoutParams as ViewGroup.MarginLayoutParams
|
||||
val m = margins.toInt()
|
||||
params.marginStart = m
|
||||
view.layoutParams = params
|
||||
}
|
||||
|
||||
@BindingAdapter("focusNextOnInput")
|
||||
fun focusNextOnInput(editText: EditText, enabled: Boolean) {
|
||||
if (!enabled) return
|
||||
|
|
|
|||
|
|
@ -90,7 +90,6 @@
|
|||
android:id="@+id/conversations_list"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
app:layout_constraintStart_toEndOf="@id/bottom_nav_bar"
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@
|
|||
android:id="@+id/meeting_info"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:visibility="@{model.meetingFound ? View.VISIBLE : View.GONE}"
|
||||
android:visibility="@{model.meetingFound ? View.VISIBLE : View.GONE, default=gone}"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
layout="@layout/chat_bubble_meeting_invite_content"
|
||||
|
|
|
|||
|
|
@ -28,8 +28,8 @@
|
|||
android:onLongClick="@{onLongClickListener}"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:layout_marginStart="8dp"
|
||||
android:layout_marginEnd="32dp"
|
||||
android:layout_marginTop="@{model.isGroupedWithPreviousOne ? @dimen/chat_bubble_grouped_top_margin : @dimen/chat_bubble_top_margin, default=@dimen/chat_bubble_top_margin}">
|
||||
|
||||
<com.google.android.material.imageview.ShapeableImageView
|
||||
|
|
@ -114,7 +114,7 @@
|
|||
android:id="@+id/background"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
android:layout_marginStart="10dp"
|
||||
android:layout_marginStart="@{model.isFromGroup ? @dimen/chat_bubble_start_margin_when_avatar_displayed : @dimen/zero, default=@dimen/chat_bubble_start_margin_when_avatar_displayed}"
|
||||
android:src="@{model.isGroupedWithPreviousOne ? @drawable/shape_chat_bubble_incoming_full : @drawable/shape_chat_bubble_incoming_first, default=@drawable/shape_chat_bubble_incoming_first}"
|
||||
app:layout_constraintStart_toEndOf="@id/avatar"
|
||||
app:layout_constraintEnd_toEndOf="@id/background_end_barrier"
|
||||
|
|
|
|||
|
|
@ -28,8 +28,8 @@
|
|||
android:onLongClick="@{onLongClickListener}"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:layout_marginStart="32dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:layout_marginTop="@{model.isGroupedWithPreviousOne ? @dimen/chat_bubble_grouped_top_margin : @dimen/chat_bubble_top_margin, default=@dimen/chat_bubble_top_margin}">
|
||||
|
||||
<androidx.constraintlayout.widget.Barrier
|
||||
|
|
|
|||
|
|
@ -80,7 +80,6 @@
|
|||
android:id="@+id/conversations_list"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:layout_marginStart="16dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
|
|
|
|||
|
|
@ -68,6 +68,7 @@
|
|||
<dimen name="chat_bubble_long_press_emoji_reaction_size">30sp</dimen>
|
||||
<dimen name="chat_bubble_big_image_max_size">200dp</dimen>
|
||||
<dimen name="chat_bubble_images_rounded_corner_radius">5dp</dimen>
|
||||
<dimen name="chat_bubble_start_margin_when_avatar_displayed">10dp</dimen>
|
||||
|
||||
<dimen name="chat_room_emoji_picker_height">290dp</dimen>
|
||||
<dimen name="chat_bubble_emoji_picker_height">425dp</dimen>
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue