Merge branch 'working' into 'develop'

move quick reply to a separate file

See merge request tom79/fedilab!282
This commit is contained in:
Thomas 2019-07-03 21:27:41 +02:00
commit 8836b17e0b
6 changed files with 102 additions and 421 deletions

View File

@ -376,93 +376,11 @@
</androidx.constraintlayout.widget.ConstraintLayout>
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/quick_reply_container"
<include
layout="@layout/layout_quick_reply"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:background="@drawable/quick_reply_background"
android:padding="10dp"
android:visibility="gone">
<TextView
android:id="@+id/warning_message"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@drawable/red_border"
android:gravity="center"
android:text="@string/reply_might_be_useless"
android:textColor="@color/red_1"
android:visibility="gone"
app:layout_constraintTop_toTopOf="parent" />
<app.fedilab.android.helper.MastalabAutoCompleteTextView
android:id="@+id/quick_reply_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="5dp"
android:gravity="top|start"
android:hint="@string/toot_placeholder"
android:inputType="textMultiLine|textCapSentences"
android:minLines="4"
app:layout_constraintTop_toBottomOf="@id/warning_message"
app:layout_goneMarginTop="0dp" />
<ImageView
android:id="@+id/quick_reply_switch_to_full"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginEnd="10dp"
android:src="@drawable/ic_zoom_out"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<TextView
android:id="@+id/toot_space_left"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginStart="10dp"
android:layout_marginTop="10dp"
android:layout_weight="1"
android:gravity="center_vertical"
android:text="500"
android:textColor="?colorAccent"
app:layout_constraintEnd_toStartOf="@id/quick_reply_emoji"
app:layout_constraintStart_toEndOf="@id/quick_reply_switch_to_full"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<ImageView
android:id="@+id/quick_reply_emoji"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginEnd="10dp"
android:src="@drawable/emoji_one_category_smileysandpeople"
app:layout_constraintEnd_toStartOf="@id/quick_reply_privacy"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<ImageView
android:id="@+id/quick_reply_privacy"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginEnd="10dp"
android:src="@drawable/ic_public"
app:layout_constraintEnd_toStartOf="@id/quick_reply_button"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<Button
android:id="@+id/quick_reply_button"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:text="@string/reply"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
</androidx.constraintlayout.widget.ConstraintLayout>
android:layout_marginTop="10dp" />
</LinearLayout>

View File

@ -1067,94 +1067,13 @@
</androidx.constraintlayout.widget.ConstraintLayout>
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/quick_reply_container"
<include
layout="@layout/layout_quick_reply"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:background="@drawable/quick_reply_background"
android:padding="10dp"
android:visibility="gone"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintTop_toBottomOf="@id/status_action_container">
<TextView
android:id="@+id/warning_message"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@drawable/red_border"
android:gravity="center"
android:text="@string/reply_might_be_useless"
android:textColor="@color/red_1"
android:visibility="gone"
app:layout_constraintTop_toTopOf="parent" />
<app.fedilab.android.helper.MastalabAutoCompleteTextView
android:id="@+id/quick_reply_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="5dp"
android:gravity="top|start"
android:hint="@string/toot_placeholder"
android:inputType="textMultiLine|textCapSentences"
android:minLines="4"
app:layout_constraintTop_toBottomOf="@id/warning_message"
app:layout_goneMarginTop="0dp" />
<ImageView
android:id="@+id/quick_reply_switch_to_full"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginEnd="10dp"
android:src="@drawable/ic_zoom_out"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<TextView
android:id="@+id/toot_space_left"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginStart="10dp"
android:layout_marginTop="10dp"
android:layout_weight="1"
android:gravity="center_vertical"
android:text="0"
android:textColor="?colorAccent"
app:layout_constraintEnd_toStartOf="@id/quick_reply_emoji"
app:layout_constraintStart_toEndOf="@id/quick_reply_switch_to_full"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<ImageView
android:id="@+id/quick_reply_emoji"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginEnd="10dp"
android:src="@drawable/emoji_one_category_smileysandpeople"
app:layout_constraintEnd_toStartOf="@id/quick_reply_privacy"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<ImageView
android:id="@+id/quick_reply_privacy"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginEnd="10dp"
android:src="@drawable/ic_public"
app:layout_constraintEnd_toStartOf="@id/quick_reply_button"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<Button
android:id="@+id/quick_reply_button"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:text="@string/reply"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
</androidx.constraintlayout.widget.ConstraintLayout>
app:layout_constraintTop_toBottomOf="@id/status_action_container" />
</androidx.constraintlayout.widget.ConstraintLayout>

View File

@ -809,92 +809,11 @@
app:layout_constraintTop_toTopOf="parent" />
</androidx.constraintlayout.widget.ConstraintLayout>
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/quick_reply_container"
<include
layout="@layout/layout_quick_reply"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:background="@drawable/quick_reply_background"
android:padding="10dp"
android:visibility="gone">
<TextView
android:id="@+id/warning_message"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@drawable/red_border"
android:gravity="center"
android:text="@string/reply_might_be_useless"
android:textColor="@color/red_1"
android:visibility="gone"
app:layout_constraintTop_toTopOf="parent" />
<app.fedilab.android.helper.MastalabAutoCompleteTextView
android:id="@+id/quick_reply_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="5dp"
android:gravity="top|start"
android:hint="@string/toot_placeholder"
android:inputType="textMultiLine|textCapSentences"
android:minLines="4"
app:layout_constraintTop_toBottomOf="@id/warning_message"
app:layout_goneMarginTop="0dp" />
<ImageView
android:id="@+id/quick_reply_switch_to_full"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginEnd="10dp"
android:src="@drawable/ic_zoom_out"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<TextView
android:id="@+id/toot_space_left"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginStart="10dp"
android:layout_marginTop="10dp"
android:layout_weight="1"
android:gravity="center_vertical"
android:text="500"
android:textColor="?colorAccent"
app:layout_constraintEnd_toStartOf="@id/quick_reply_emoji"
app:layout_constraintStart_toEndOf="@id/quick_reply_switch_to_full"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<ImageView
android:id="@+id/quick_reply_emoji"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginEnd="10dp"
android:src="@drawable/emoji_one_category_smileysandpeople"
app:layout_constraintEnd_toStartOf="@id/quick_reply_privacy"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<ImageView
android:id="@+id/quick_reply_privacy"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginEnd="10dp"
android:src="@drawable/ic_public"
app:layout_constraintEnd_toStartOf="@id/quick_reply_button"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<Button
android:id="@+id/quick_reply_button"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:text="@string/reply"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
</androidx.constraintlayout.widget.ConstraintLayout>
android:layout_marginTop="10dp" />
<LinearLayout
android:visibility="gone"

View File

@ -799,92 +799,11 @@
</androidx.constraintlayout.widget.ConstraintLayout>
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/quick_reply_container"
<include
layout="@layout/layout_quick_reply"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:background="@drawable/quick_reply_background"
android:padding="10dp"
android:visibility="gone">
<TextView
android:id="@+id/warning_message"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@drawable/red_border"
android:gravity="center"
android:text="@string/reply_might_be_useless"
android:textColor="@color/red_1"
android:visibility="gone"
app:layout_constraintTop_toTopOf="parent" />
<app.fedilab.android.helper.MastalabAutoCompleteTextView
android:id="@+id/quick_reply_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="5dp"
android:gravity="top|start"
android:hint="@string/toot_placeholder"
android:inputType="textMultiLine|textCapSentences"
android:minLines="4"
app:layout_constraintTop_toBottomOf="@id/warning_message"
app:layout_goneMarginTop="0dp" />
<ImageView
android:id="@+id/quick_reply_switch_to_full"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginEnd="10dp"
android:src="@drawable/ic_zoom_out"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<TextView
android:id="@+id/toot_space_left"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginStart="10dp"
android:layout_marginTop="10dp"
android:layout_weight="1"
android:gravity="center_vertical"
android:text="500"
android:textColor="?colorAccent"
app:layout_constraintEnd_toStartOf="@id/quick_reply_emoji"
app:layout_constraintStart_toEndOf="@id/quick_reply_switch_to_full"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<ImageView
android:id="@+id/quick_reply_emoji"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginEnd="10dp"
android:src="@drawable/emoji_one_category_smileysandpeople"
app:layout_constraintEnd_toStartOf="@id/quick_reply_privacy"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<ImageView
android:id="@+id/quick_reply_privacy"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginEnd="10dp"
android:src="@drawable/ic_public"
app:layout_constraintEnd_toStartOf="@id/quick_reply_button"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<Button
android:id="@+id/quick_reply_button"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:text="@string/reply"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
</androidx.constraintlayout.widget.ConstraintLayout>
android:layout_marginTop="10dp" />
<LinearLayout
android:visibility="gone"

View File

@ -729,92 +729,11 @@
app:layout_constraintTop_toTopOf="parent" />
</androidx.constraintlayout.widget.ConstraintLayout>
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/quick_reply_container"
<include
layout="@layout/layout_quick_reply"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:background="@drawable/quick_reply_background"
android:padding="10dp"
android:visibility="gone">
<TextView
android:id="@+id/warning_message"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@drawable/red_border"
android:gravity="center"
android:text="@string/reply_might_be_useless"
android:textColor="@color/red_1"
android:visibility="gone"
app:layout_constraintTop_toTopOf="parent" />
<app.fedilab.android.helper.MastalabAutoCompleteTextView
android:id="@+id/quick_reply_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="5dp"
android:gravity="top|start"
android:hint="@string/toot_placeholder"
android:inputType="textMultiLine|textCapSentences"
android:minLines="4"
app:layout_constraintTop_toBottomOf="@id/warning_message"
app:layout_goneMarginTop="0dp" />
<ImageView
android:id="@+id/quick_reply_switch_to_full"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginEnd="10dp"
android:src="@drawable/ic_zoom_out"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<TextView
android:id="@+id/toot_space_left"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginStart="10dp"
android:layout_marginTop="10dp"
android:layout_weight="1"
android:gravity="center_vertical"
android:text="500"
android:textColor="?colorAccent"
app:layout_constraintEnd_toStartOf="@id/quick_reply_emoji"
app:layout_constraintStart_toEndOf="@id/quick_reply_switch_to_full"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<ImageView
android:id="@+id/quick_reply_emoji"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginEnd="10dp"
android:src="@drawable/emoji_one_category_smileysandpeople"
app:layout_constraintEnd_toStartOf="@id/quick_reply_privacy"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<ImageView
android:id="@+id/quick_reply_privacy"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginEnd="10dp"
android:src="@drawable/ic_public"
app:layout_constraintEnd_toStartOf="@id/quick_reply_button"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<Button
android:id="@+id/quick_reply_button"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:text="@string/reply"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
</androidx.constraintlayout.widget.ConstraintLayout>
android:layout_marginTop="10dp" />
<Button
android:id="@+id/fetch_more"

View File

@ -0,0 +1,87 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/quick_reply_container"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@drawable/quick_reply_background"
android:padding="10dp"
android:visibility="gone">
<TextView
android:id="@+id/warning_message"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@drawable/red_border"
android:gravity="center"
android:text="@string/reply_might_be_useless"
android:textColor="@color/red_1"
android:visibility="gone"
app:layout_constraintTop_toTopOf="parent" />
<app.fedilab.android.helper.MastalabAutoCompleteTextView
android:id="@+id/quick_reply_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="5dp"
android:gravity="top|start"
android:hint="@string/toot_placeholder"
android:inputType="textMultiLine|textCapSentences"
android:minLines="4"
app:layout_constraintTop_toBottomOf="@id/warning_message"
app:layout_goneMarginTop="0dp" />
<ImageView
android:id="@+id/quick_reply_switch_to_full"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginEnd="10dp"
android:src="@drawable/ic_zoom_out"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<TextView
android:id="@+id/toot_space_left"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginStart="10dp"
android:layout_marginTop="10dp"
android:layout_weight="1"
android:gravity="center_vertical"
android:text="0"
android:textColor="?colorAccent"
app:layout_constraintEnd_toStartOf="@id/quick_reply_emoji"
app:layout_constraintStart_toEndOf="@id/quick_reply_switch_to_full"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<ImageView
android:id="@+id/quick_reply_emoji"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginEnd="10dp"
android:src="@drawable/emoji_one_category_smileysandpeople"
app:layout_constraintEnd_toStartOf="@id/quick_reply_privacy"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<ImageView
android:id="@+id/quick_reply_privacy"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:layout_marginEnd="10dp"
android:src="@drawable/ic_public"
app:layout_constraintEnd_toStartOf="@id/quick_reply_button"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
<Button
android:id="@+id/quick_reply_button"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginTop="10dp"
android:text="@string/reply"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toBottomOf="@id/quick_reply_text" />
</androidx.constraintlayout.widget.ConstraintLayout>