app/src/main/res/layout/activity_settings.xml
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout 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="wrap_content"
android:fillViewport="false"
tools:context=".main_screen.profile.settings.Settings"
android:orientation="vertical">
<androidx.appcompat.widget.Toolbar
android:id="@+id/settings_toolbar"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?attr/colorPrimary"
android:minHeight="?attr/actionBarSize"
android:theme="?attr/actionBarTheme"
app:title="@string/settings_profile" />
<TextView
android:id="@+id/account_settings_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/settings_toolbar"
android:layout_marginStart="@dimen/margin_small"
android:layout_marginTop="@dimen/margin_small"
android:text="@string/account_settings"
android:textColor="@color/blindly_purple_secondary"
android:textSize="16sp"
android:textStyle="bold" />
<View
android:id="@+id/divider"
android:layout_width="match_parent"
android:layout_height="1dp"
android:layout_below="@id/account_settings_text"
android:background="?android:attr/listDivider" />
<Button
android:id="@+id/email_button"
android:layout_width="match_parent"
android:layout_height="@dimen/cell_height"
android:layout_below="@id/divider"
android:background="@color/transparent"
android:foreground="?selectableItemBackground"
android:onClick="startUpdateEmail" />
<TextView
android:id="@+id/email_text"
android:layout_width="wrap_content"
android:layout_height="@dimen/cell_height"
android:layout_below="@id/divider"
android:layout_marginStart="@dimen/margin_small"
android:gravity="center"
android:text="@string/email"
android:textSize="15sp"
android:textStyle="bold" />
<ImageView
android:id="@+id/email_arrow"
android:layout_width="@dimen/arrow_width"
android:layout_height="@dimen/arrow_height"
android:layout_alignParentEnd="true"
android:layout_below="@id/divider"
android:layout_marginTop="@dimen/margin_top_arrow"
android:layout_marginEnd="@dimen/margin_small"
android:contentDescription="@string/arrow_button_to_show_e_mail"
app:srcCompat="@drawable/arrow_button" />
<TextView
android:id="@+id/email_address_text"
android:layout_width="wrap_content"
android:layout_height="@dimen/cell_height"
android:layout_below="@id/divider"
android:layout_marginEnd="@dimen/margin_extra_small"
android:layout_toStartOf="@id/email_arrow"
android:gravity="center"
android:textSize="15sp" />
<View
android:id="@+id/divider_mail"
android:layout_width="match_parent"
android:layout_height="1dp"
android:layout_below="@id/email_text"
android:background="?android:attr/listDivider" />
<TextView
android:id="@+id/discovery_settings_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/divider_mail"
android:layout_marginTop="@dimen/cell_height"
android:layout_marginStart="@dimen/margin_small"
android:text="@string/discovery_settings"
android:textColor="@color/blindly_purple_secondary"
android:textSize="16sp"
android:textStyle="bold" />
<View
android:id="@+id/divider2"
android:layout_width="match_parent"
android:layout_height="1dp"
android:layout_below="@id/discovery_settings_text"
android:background="?android:attr/listDivider" />
<Button
android:id="@+id/location_button"
android:layout_width="match_parent"
android:layout_height="@dimen/cell_height"
android:layout_below="@id/divider2"
android:background="@color/transparent"
android:foreground="?selectableItemBackground"
android:onClick="startLocationSettings" />
<TextView
android:id="@+id/location_text"
android:layout_width="wrap_content"
android:layout_height="@dimen/cell_height"
android:layout_below="@id/divider2"
android:layout_marginStart="@dimen/margin_small"
android:gravity="center"
android:text="@string/location"
android:textSize="15sp"
android:textStyle="bold" />
<TextView
android:id="@+id/current_location_text"
android:layout_width="wrap_content"
android:layout_height="@dimen/cell_height"
android:layout_marginEnd="@dimen/margin_extra_small"
android:layout_below="@id/divider2"
android:layout_toStartOf="@id/location_arrow"
android:gravity="center"
android:textSize="15sp" />
<ImageView
android:id="@+id/location_arrow"
android:layout_width="@dimen/arrow_width"
android:layout_height="@dimen/arrow_height"
android:layout_alignParentEnd="true"
android:layout_below="@id/divider2"
android:layout_marginTop="@dimen/margin_top_arrow"
android:layout_marginEnd="@dimen/margin_small"
android:contentDescription="@string/arrow_button_to_show_location"
app:srcCompat="@drawable/arrow_button" />
<View
android:id="@+id/divider_location"
android:layout_width="match_parent"
android:layout_height="1dp"
android:layout_below="@id/location_text"
android:background="?android:attr/listDivider" />
<TextView
android:id="@+id/maximum_distance_text"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@id/divider_location"
android:layout_marginStart="@dimen/margin_small"
android:layout_marginTop="5dp"
android:gravity="top"
android:text="@string/maximum_distance"
android:textSize="15sp"
android:textStyle="bold" />
<TextView
android:id="@+id/radius_text"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@id/divider_location"
android:layout_alignParentEnd="true"
android:layout_marginTop="5dp"
android:layout_marginEnd="39dp"
android:gravity="top"
android:textSize="15sp" />
<com.google.android.material.slider.Slider
android:id="@+id/location_slider"
android:layout_width="match_parent"
android:layout_height="40dp"
android:layout_below="@+id/maximum_distance_text"
android:layout_marginStart="@dimen/margin_small"
android:layout_marginEnd="@dimen/margin_small"
android:gravity="center"
android:stepSize="1"
android:value="50"
android:valueFrom="0.0"
android:valueTo="200.0"
app:thumbRadius="6dp"
app:tickVisible="false"
app:trackHeight="2dp" />
<View
android:id="@+id/divider_distance"
android:layout_width="match_parent"
android:layout_height="1dp"
android:layout_below="@id/location_slider"
android:background="?android:attr/listDivider" />
<Button
android:id="@+id/show_me_button"
android:layout_width="match_parent"
android:layout_height="50dp"
android:layout_below="@id/divider_distance"
android:background="@color/transparent"
android:foreground="?selectableItemBackground"
android:onClick="startShowMeSettings" />
<TextView
android:id="@+id/looking_for_text"
android:layout_width="wrap_content"
android:layout_height="@dimen/cell_height"
android:layout_below="@id/divider_distance"
android:layout_marginStart="@dimen/margin_small"
android:gravity="center"
android:text="@string/looking_for"
android:textSize="15sp"
android:textStyle="bold" />
<TextView
android:id="@+id/show_me_text"
android:layout_width="wrap_content"
android:layout_height="@dimen/cell_height"
android:layout_below="@id/divider_distance"
android:layout_marginEnd="@dimen/margin_extra_small"
android:layout_toStartOf="@id/show_me_arrow"
android:gravity="center"
android:textSize="15sp" />
<ImageView
android:id="@+id/show_me_arrow"
android:layout_width="@dimen/arrow_width"
android:layout_height="@dimen/arrow_height"
android:layout_alignParentEnd="true"
android:layout_below="@id/divider_distance"
android:layout_marginTop="@dimen/margin_top_arrow"
android:layout_marginEnd="@dimen/margin_small"
android:contentDescription="@string/arrow_button_to_show_show_me_settings"
app:srcCompat="@drawable/arrow_button" />
<View
android:id="@+id/divider_showme"
android:layout_width="match_parent"
android:layout_height="1dp"
android:layout_below="@id/looking_for_text"
android:background="?android:attr/listDivider" />
<TextView
android:id="@+id/age_range_text"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@+id/divider_showme"
android:layout_marginStart="@dimen/margin_small"
android:layout_marginTop="5dp"
android:gravity="center"
android:text="@string/age_range"
android:textSize="15sp"
android:textStyle="bold" />
<TextView
android:id="@+id/selected_age_range_text"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@+id/divider_showme"
android:layout_alignParentEnd="true"
android:layout_marginTop="5dp"
android:layout_marginEnd="39dp"
android:gravity="top"
android:textSize="15sp" />
<com.google.android.material.slider.RangeSlider
android:id="@+id/age_range_slider"
android:layout_width="match_parent"
android:layout_height="40dp"
android:layout_below="@+id/age_range_text"
android:layout_marginStart="@dimen/margin_small"
android:layout_marginEnd="@dimen/margin_small"
android:gravity="center"
android:stepSize="1"
android:valueFrom="18"
android:valueTo="99"
app:thumbRadius="6dp"
app:tickVisible="false"
app:trackHeight="2dp"
app:values="@array/initial_slider_values"/>
<View
android:id="@+id/divider_agerange"
android:layout_width="match_parent"
android:layout_height="1dp"
android:layout_below="@id/age_range_slider"
android:background="?android:attr/listDivider" />
<com.google.android.material.button.MaterialButton
android:id="@+id/logout_button"
android:layout_width="@dimen/pill_shape_width"
android:layout_height="@dimen/pill_shape_height"
android:layout_below="@id/divider_agerange"
android:layout_marginTop="@dimen/margin"
android:layout_centerHorizontal="true"
android:layout_marginBottom="@dimen/margin_small"
android:onClick="logout"
android:text="@string/logout_button_text"
app:shapeAppearanceOverlay="@style/PillShapeButton" />
<com.google.android.material.button.MaterialButton
android:id="@+id/delete_account_button"
android:layout_width="@dimen/pill_shape_width"
android:layout_height="@dimen/pill_shape_height"
android:layout_below="@id/logout_button"
android:layout_centerHorizontal="true"
android:onClick="deleteAccount"
android:text="@string/delete_account_button_text"
app:shapeAppearanceOverlay="@style/PillShapeButton" />
</RelativeLayout>