[android] Re-factor TextInputViews

This commit is contained in:
Torsten Grote
2018-12-03 11:52:39 -02:00
parent f536cfdab8
commit 8fe49d9961
27 changed files with 416 additions and 266 deletions

View File

@@ -32,9 +32,9 @@
android:layout_height="match_parent"
android:layout_marginLeft="@dimen/margin_medium"
android:layout_marginStart="@dimen/margin_medium"
android:ellipsize="end"
android:gravity="center"
android:maxLines="1"
android:ellipsize="end"
android:textColor="@color/action_bar_text"
tools:text="Contact Name of someone who chose a long name"/>
@@ -54,6 +54,7 @@
android:id="@+id/text_input_container"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:hint="@string/message_hint"/>
app:hint="@string/message_hint"
app:supportsAttachments="true"/>
</LinearLayout>

View File

@@ -5,6 +5,7 @@
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:allowEmptyText="true"
app:buttonText="@string/forum_share_button"
app:fillHeight="true"
app:hint="@string/forum_share_message"/>

View File

@@ -39,6 +39,7 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="bottom"
app:allowEmptyText="true"
app:buttonText="@string/blogs_reblog_button"
app:hint="@string/blogs_reblog_comment_hint"
app:maxLines="5"/>

View File

@@ -118,6 +118,7 @@
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/margin_large"
android:visibility="gone"
app:allowEmptyText="true"
app:buttonText="@string/introduction_button"
app:hint="@string/introduction_message_hint"
app:layout_constraintBottom_toBottomOf="parent"

View File

@@ -78,20 +78,6 @@
android:layout_height="@dimen/text_input_height"
android:layout_gravity="bottom">
<android.support.v7.widget.AppCompatImageButton
android:id="@+id/btn_send"
android:layout_width="@dimen/text_input_height"
android:layout_height="@dimen/text_input_height"
android:background="?attr/selectableItemBackground"
android:clickable="true"
android:contentDescription="@string/send"
android:enabled="false"
android:focusable="true"
android:padding="4dp"
android:scaleType="center"
android:src="@drawable/social_send_now_white"
app:tint="@color/briar_accent"/>
<android.support.v7.widget.AppCompatImageButton
android:id="@+id/imageButton"
android:layout_width="@dimen/text_input_height"
@@ -107,6 +93,20 @@
android:visibility="invisible"
app:tint="?attr/colorControlNormal"/>
<android.support.v7.widget.AppCompatImageButton
android:id="@+id/btn_send"
android:layout_width="@dimen/text_input_height"
android:layout_height="@dimen/text_input_height"
android:background="?attr/selectableItemBackground"
android:clickable="true"
android:contentDescription="@string/send"
android:enabled="false"
android:focusable="true"
android:padding="4dp"
android:scaleType="center"
android:src="@drawable/social_send_now_white"
app:tint="@color/briar_accent"/>
</FrameLayout>
</LinearLayout>

View File

@@ -21,6 +21,8 @@
<declare-styleable name="TextInputView">
<attr name="hint" format="string"/>
<attr name="allowEmptyText" format="boolean"/>
<attr name="supportsAttachments" format="boolean"/>
</declare-styleable>
<declare-styleable name="LargeTextInputView">