135 lines
7.4 KiB
XML
135 lines
7.4 KiB
XML
|
<!-- this replaces the default material_drawer_header.xml from the MaterialDrawer library -->
|
||
|
<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/material_drawer_account_header"
|
||
|
android:layout_width="match_parent"
|
||
|
android:layout_height="@dimen/material_drawer_account_header_height"
|
||
|
android:clickable="true">
|
||
|
|
||
|
<androidx.appcompat.widget.AppCompatImageView
|
||
|
android:id="@+id/material_drawer_account_header_background"
|
||
|
android:layout_width="match_parent"
|
||
|
android:layout_height="@dimen/material_drawer_account_header_height"
|
||
|
android:scaleType="centerCrop"
|
||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||
|
app:layout_constraintEnd_toEndOf="parent"
|
||
|
app:layout_constraintStart_toStartOf="parent"
|
||
|
app:layout_constraintTop_toTopOf="parent" />
|
||
|
|
||
|
<androidx.constraintlayout.widget.Guideline
|
||
|
android:id="@+id/material_drawer_statusbar_guideline"
|
||
|
android:layout_width="wrap_content"
|
||
|
android:layout_height="wrap_content"
|
||
|
android:orientation="horizontal"
|
||
|
app:layout_constraintGuide_begin="0dp" />
|
||
|
|
||
|
<com.keylesspalace.tusky.view.BezelImageView
|
||
|
android:id="@+id/material_drawer_account_header_current"
|
||
|
android:layout_width="@dimen/material_drawer_account_header_selected"
|
||
|
android:layout_height="@dimen/material_drawer_account_header_selected"
|
||
|
android:layout_marginStart="@dimen/material_drawer_vertical_padding"
|
||
|
android:layout_marginLeft="@dimen/material_drawer_vertical_padding"
|
||
|
android:layout_marginTop="@dimen/material_drawer_account_header_horizontal_top"
|
||
|
android:clickable="true"
|
||
|
android:elevation="8dp"
|
||
|
android:focusable="true"
|
||
|
android:src="@drawable/avatar_default"
|
||
|
app:biv_maskDrawable="@drawable/materialdrawer_shape_large"
|
||
|
app:layout_constraintStart_toStartOf="parent"
|
||
|
app:layout_constraintTop_toBottomOf="@+id/material_drawer_statusbar_guideline" />
|
||
|
|
||
|
<com.keylesspalace.tusky.view.BezelImageView
|
||
|
android:id="@+id/material_drawer_account_header_small_first"
|
||
|
android:layout_width="@dimen/material_drawer_account_header_secondary"
|
||
|
android:layout_height="@dimen/material_drawer_account_header_secondary"
|
||
|
android:layout_marginTop="@dimen/material_drawer_account_header_horizontal_top"
|
||
|
android:layout_marginEnd="@dimen/material_drawer_vertical_padding"
|
||
|
android:layout_marginRight="@dimen/material_drawer_vertical_padding"
|
||
|
android:clickable="true"
|
||
|
android:elevation="8dp"
|
||
|
android:focusable="true"
|
||
|
android:src="@drawable/avatar_default"
|
||
|
app:biv_maskDrawable="@drawable/materialdrawer_shape_small"
|
||
|
app:layout_constraintEnd_toStartOf="@id/material_drawer_account_header_small_second"
|
||
|
app:layout_constraintTop_toBottomOf="@+id/material_drawer_statusbar_guideline" />
|
||
|
|
||
|
<com.keylesspalace.tusky.view.BezelImageView
|
||
|
android:id="@+id/material_drawer_account_header_small_second"
|
||
|
android:layout_width="@dimen/material_drawer_account_header_secondary"
|
||
|
android:layout_height="@dimen/material_drawer_account_header_secondary"
|
||
|
android:layout_marginTop="@dimen/material_drawer_account_header_horizontal_top"
|
||
|
android:layout_marginEnd="@dimen/material_drawer_vertical_padding"
|
||
|
android:layout_marginRight="@dimen/material_drawer_vertical_padding"
|
||
|
android:clickable="true"
|
||
|
android:elevation="8dp"
|
||
|
android:focusable="true"
|
||
|
android:src="@drawable/avatar_default"
|
||
|
app:biv_maskDrawable="@drawable/materialdrawer_shape_small"
|
||
|
app:layout_constraintEnd_toStartOf="@id/material_drawer_account_header_small_third"
|
||
|
app:layout_constraintTop_toBottomOf="@+id/material_drawer_statusbar_guideline" />
|
||
|
|
||
|
<com.keylesspalace.tusky.view.BezelImageView
|
||
|
android:id="@+id/material_drawer_account_header_small_third"
|
||
|
android:layout_width="@dimen/material_drawer_account_header_secondary"
|
||
|
android:layout_height="@dimen/material_drawer_account_header_secondary"
|
||
|
android:layout_marginTop="@dimen/material_drawer_account_header_horizontal_top"
|
||
|
android:layout_marginEnd="@dimen/material_drawer_vertical_padding"
|
||
|
android:layout_marginRight="@dimen/material_drawer_vertical_padding"
|
||
|
android:clickable="true"
|
||
|
android:elevation="8dp"
|
||
|
android:focusable="true"
|
||
|
android:src="@drawable/avatar_default"
|
||
|
app:biv_maskDrawable="@drawable/materialdrawer_shape_small"
|
||
|
app:layout_constraintEnd_toEndOf="parent"
|
||
|
app:layout_constraintTop_toBottomOf="@+id/material_drawer_statusbar_guideline" />
|
||
|
|
||
|
<androidx.constraintlayout.widget.Guideline
|
||
|
android:id="@+id/material_drawer_text_guideline"
|
||
|
android:layout_width="wrap_content"
|
||
|
android:layout_height="wrap_content"
|
||
|
android:orientation="horizontal"
|
||
|
app:layout_constraintGuide_end="@dimen/material_drawer_account_header_dropdown_guideline" />
|
||
|
|
||
|
<androidx.appcompat.widget.AppCompatTextView
|
||
|
android:id="@+id/material_drawer_account_header_name"
|
||
|
android:layout_width="0dp"
|
||
|
android:layout_height="wrap_content"
|
||
|
android:layout_marginStart="@dimen/material_drawer_vertical_padding"
|
||
|
android:layout_marginLeft="@dimen/material_drawer_vertical_padding"
|
||
|
android:fontFamily="sans-serif-medium"
|
||
|
android:lines="1"
|
||
|
android:maxLines="1"
|
||
|
android:textSize="@dimen/material_drawer_account_header_title"
|
||
|
app:layout_constraintBottom_toTopOf="@id/material_drawer_account_header_email"
|
||
|
app:layout_constraintEnd_toStartOf="@id/material_drawer_account_header_text_switcher"
|
||
|
app:layout_constraintStart_toStartOf="parent"
|
||
|
app:layout_constraintTop_toBottomOf="@id/material_drawer_text_guideline"
|
||
|
app:layout_constraintVertical_chainStyle="packed" />
|
||
|
|
||
|
<androidx.appcompat.widget.AppCompatTextView
|
||
|
android:id="@+id/material_drawer_account_header_email"
|
||
|
android:layout_width="0dp"
|
||
|
android:layout_height="wrap_content"
|
||
|
android:layout_marginStart="@dimen/material_drawer_vertical_padding"
|
||
|
android:layout_marginLeft="@dimen/material_drawer_vertical_padding"
|
||
|
android:layout_marginBottom="@dimen/material_drawer_padding"
|
||
|
android:fontFamily="sans-serif"
|
||
|
android:lines="1"
|
||
|
android:maxLines="1"
|
||
|
android:textSize="@dimen/material_drawer_account_header_subtext"
|
||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||
|
app:layout_constraintEnd_toStartOf="@id/material_drawer_account_header_text_switcher"
|
||
|
app:layout_constraintStart_toStartOf="parent"
|
||
|
app:layout_constraintTop_toBottomOf="@id/material_drawer_account_header_name" />
|
||
|
|
||
|
<androidx.appcompat.widget.AppCompatImageView
|
||
|
android:id="@+id/material_drawer_account_header_text_switcher"
|
||
|
android:layout_width="@dimen/material_drawer_account_header_dropdown"
|
||
|
android:layout_height="@dimen/material_drawer_account_header_dropdown"
|
||
|
android:layout_marginEnd="@dimen/material_drawer_vertical_padding"
|
||
|
android:layout_marginRight="@dimen/material_drawer_vertical_padding"
|
||
|
android:layout_marginBottom="@dimen/material_drawer_account_header_dropdown_margin_bottom"
|
||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||
|
app:layout_constraintEnd_toEndOf="parent" />
|
||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|