activity_change_password.xml

  1<?xml version="1.0" encoding="utf-8"?>
  2<layout xmlns:android="http://schemas.android.com/apk/res/android"
  3    xmlns:app="http://schemas.android.com/apk/res-auto">
  4
  5    <RelativeLayout
  6        android:layout_width="match_parent"
  7        android:layout_height="match_parent"
  8        android:fitsSystemWindows="true">
  9
 10        <com.google.android.material.appbar.AppBarLayout
 11            android:id="@+id/app_bar_layout"
 12            android:layout_width="match_parent"
 13            android:layout_height="wrap_content">
 14
 15            <com.google.android.material.appbar.MaterialToolbar
 16                android:id="@+id/toolbar"
 17                android:layout_width="match_parent"
 18                android:layout_height="wrap_content"
 19                android:minHeight="?attr/actionBarSize" />
 20        </com.google.android.material.appbar.AppBarLayout>
 21
 22        <ScrollView
 23            android:layout_width="fill_parent"
 24            android:layout_height="fill_parent"
 25            android:layout_above="@+id/button_bar"
 26            android:layout_below="@id/app_bar_layout">
 27
 28            <LinearLayout
 29                android:layout_width="match_parent"
 30                android:layout_height="wrap_content"
 31                android:layout_marginLeft="@dimen/activity_horizontal_margin"
 32                android:layout_marginTop="@dimen/activity_vertical_margin"
 33                android:layout_marginRight="@dimen/activity_horizontal_margin"
 34                android:layout_marginBottom="@dimen/activity_vertical_margin">
 35
 36                <LinearLayout
 37                    android:layout_width="match_parent"
 38                    android:layout_height="wrap_content"
 39                    android:orientation="vertical"
 40                    android:padding="@dimen/card_padding_regular">
 41
 42
 43                    <com.google.android.material.textfield.TextInputLayout
 44                        android:id="@+id/current_password_layout"
 45                        android:layout_width="match_parent"
 46                        android:layout_height="wrap_content"
 47                        android:hint="@string/current_password"
 48                        app:endIconMode="password_toggle">
 49
 50                        <eu.siacs.conversations.ui.widget.TextInputEditText
 51                            android:id="@+id/current_password"
 52                            android:layout_width="match_parent"
 53                            android:layout_height="wrap_content"
 54                            android:layout_alignParentTop="true"
 55                            android:inputType="textPassword" />
 56                    </com.google.android.material.textfield.TextInputLayout>
 57
 58                    <com.google.android.material.textfield.TextInputLayout
 59                        android:id="@+id/new_password_layout"
 60                        android:layout_width="match_parent"
 61                        android:layout_height="wrap_content"
 62                        android:hint="@string/new_password"
 63                        app:endIconMode="password_toggle">
 64
 65                        <eu.siacs.conversations.ui.widget.TextInputEditText
 66                            android:id="@+id/new_password"
 67                            android:layout_width="match_parent"
 68                            android:layout_height="wrap_content"
 69                            android:layout_alignParentTop="true"
 70                            android:inputType="textPassword" />
 71                    </com.google.android.material.textfield.TextInputLayout>
 72                </LinearLayout>
 73            </LinearLayout>
 74        </ScrollView>
 75
 76        <RelativeLayout
 77            android:id="@+id/button_bar"
 78            android:layout_width="wrap_content"
 79            android:layout_height="wrap_content"
 80            android:layout_alignParentStart="true"
 81            android:layout_alignParentEnd="true"
 82            android:layout_alignParentBottom="true"
 83            android:paddingHorizontal="16dp"
 84            android:paddingVertical="8dp">
 85
 86            <Button
 87                android:id="@+id/cancel_button"
 88                style="@style/Widget.Material3.Button.TextButton"
 89                android:layout_width="wrap_content"
 90                android:layout_height="wrap_content"
 91                android:layout_alignParentStart="true"
 92                android:layout_centerInParent="true"
 93                android:text="@string/cancel" />
 94
 95
 96            <Button
 97                android:id="@+id/change_password_button"
 98                android:layout_width="wrap_content"
 99                android:layout_height="wrap_content"
100                android:layout_alignParentEnd="true"
101                android:layout_centerInParent="true"
102                android:text="@string/change_password" />
103        </RelativeLayout>
104
105
106    </RelativeLayout>
107</layout>