chinwag-android/app/src/main/res/layout/activity_edit_profile.xml
Konrad Pozniak 63ab0ef839
Fix crash in EditProfileActivity on Android 8 (#585)
* fix bug where sometimes mentions where duplicated when replying

* fix for crash on Android 8
2018-04-17 19:25:56 +02:00

153 lines
No EOL
6.2 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context="com.keylesspalace.tusky.EditProfileActivity">
<include layout="@layout/toolbar_basic" />
<ScrollView
android:layout_width="match_parent"
android:layout_height="match_parent"
app:layout_behavior="@string/appbar_scrolling_view_behavior">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:focusableInTouchMode="true"
android:orientation="vertical">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<ImageView
android:id="@+id/headerPreview"
android:layout_width="match_parent"
android:layout_height="200dp"
android:contentDescription="@null" />
<ImageButton
android:id="@+id/headerButton"
android:layout_width="match_parent"
android:layout_height="200dp"
android:background="#66000000"
android:contentDescription="@string/label_header"
app:srcCompat="@drawable/ic_add_a_photo_32dp" />
<ProgressBar
android:id="@+id/headerProgressBar"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:indeterminate="true"
android:visibility="gone" />
</RelativeLayout>
<RelativeLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="16dp"
android:layout_marginTop="-40dp">
<com.pkmmte.view.CircularImageView
android:id="@+id/avatarPreview"
android:layout_width="80dp"
android:layout_height="80dp"
android:contentDescription="@null" />
<ImageButton
android:id="@+id/avatarButton"
android:layout_width="80dp"
android:layout_height="80dp"
android:background="@drawable/round_button"
android:contentDescription="@string/label_avatar"
android:elevation="4dp"
app:srcCompat="@drawable/ic_add_a_photo_32dp" />
<ProgressBar
android:id="@+id/avatarProgressBar"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:indeterminate="true"
android:visibility="gone" />
</RelativeLayout>
<android.support.design.widget.TextInputLayout
android:id="@+id/layout_edit_profile_display_name"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="30dp">
<android.support.design.widget.TextInputEditText
android:id="@+id/displayNameEditText"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginEnd="16dp"
android:layout_marginStart="16dp"
android:hint="@string/hint_display_name"
android:importantForAutofill="no"
android:maxLength="30" />
</android.support.design.widget.TextInputLayout>
<android.support.design.widget.TextInputLayout
android:id="@+id/layout_edit_profile_note"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="30dp">
<android.support.design.widget.TextInputEditText
android:id="@+id/noteEditText"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="16dp"
android:layout_marginEnd="16dp"
android:layout_marginStart="16dp"
android:hint="@string/hint_note"
android:importantForAutofill="no"
android:maxLength="160" />
</android.support.design.widget.TextInputLayout>
<android.support.v7.widget.AppCompatCheckBox
android:id="@+id/lockedCheckBox"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginEnd="16dp"
android:layout_marginStart="16dp"
android:layout_marginTop="30dp"
android:paddingStart="8dp"
android:text="@string/lock_account_label"
android:textSize="?attr/status_text_medium" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="24dp"
android:layout_marginEnd="16dp"
android:layout_marginStart="16dp"
android:paddingStart="40dp"
android:text="@string/lock_account_label_description"
android:textSize="?attr/status_text_small" />
</LinearLayout>
</ScrollView>
<include layout="@layout/toolbar_shadow_shim" />
<ProgressBar
android:id="@+id/saveProgressBar"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:indeterminate="true"
android:visibility="gone" />
</android.support.design.widget.CoordinatorLayout>