Better account switcher
This commit is contained in:
44
mastodon/src/main/res/layout/item_account_switcher.xml
Normal file
44
mastodon/src/main/res/layout/item_account_switcher.xml
Normal file
@@ -0,0 +1,44 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:orientation="horizontal"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="48dp"
|
||||
android:paddingLeft="20dp"
|
||||
android:paddingRight="20dp"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/avatar"
|
||||
android:layout_width="32dp"
|
||||
android:layout_height="32dp"
|
||||
android:importantForAccessibility="no"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/name"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:layout_marginStart="24dp"
|
||||
android:textSize="16dp"
|
||||
android:textColor="?android:textColorPrimary"
|
||||
android:singleLine="true"
|
||||
android:ellipsize="end"/>
|
||||
|
||||
<View
|
||||
android:id="@+id/current"
|
||||
android:layout_width="24dp"
|
||||
android:layout_height="24dp"
|
||||
android:background="@drawable/ic_fluent_checkmark_24_filled"
|
||||
android:backgroundTint="?android:textColorSecondary"
|
||||
android:contentDescription="@string/current_account"/>
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/more"
|
||||
android:layout_width="24dp"
|
||||
android:layout_height="24dp"
|
||||
android:src="@drawable/ic_fluent_more_vertical_24_regular"
|
||||
android:tint="?android:textColorSecondary"
|
||||
android:contentDescription="@string/more_options"
|
||||
android:background="?android:selectableItemBackgroundBorderless"/>
|
||||
|
||||
</LinearLayout>
|
||||
@@ -12,11 +12,11 @@
|
||||
android:id="@+id/tabbar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="52dp"
|
||||
android:paddingLeft="20dp"
|
||||
android:paddingRight="20dp">
|
||||
android:paddingLeft="16dp"
|
||||
android:paddingRight="16dp">
|
||||
<ImageView
|
||||
android:id="@+id/tab_home"
|
||||
android:layout_width="52dp"
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="52dp"
|
||||
android:scaleType="center"
|
||||
android:contentDescription="@string/home_timeline"
|
||||
@@ -31,7 +31,7 @@
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/tab_search"
|
||||
android:layout_width="52dp"
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="52dp"
|
||||
android:scaleType="center"
|
||||
android:contentDescription="@string/search_hint"
|
||||
@@ -46,7 +46,7 @@
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/tab_notifications"
|
||||
android:layout_width="52dp"
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="52dp"
|
||||
android:scaleType="center"
|
||||
android:contentDescription="@string/notifications"
|
||||
@@ -61,7 +61,7 @@
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/tab_profile"
|
||||
android:layout_width="52dp"
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="52dp"
|
||||
android:contentDescription="@string/my_profile"
|
||||
android:foreground="@drawable/bg_tab_profile"
|
||||
@@ -73,6 +73,13 @@
|
||||
android:layout_gravity="center"
|
||||
android:scaleType="centerCrop"
|
||||
android:src="@null"/>
|
||||
<View
|
||||
android:layout_width="16dp"
|
||||
android:layout_height="16dp"
|
||||
android:layout_gravity="end|center_vertical"
|
||||
android:layout_marginEnd="-4dp"
|
||||
android:backgroundTint="?android:colorPrimary"
|
||||
android:background="@drawable/ic_fluent_chevron_up_down_16_regular"/>
|
||||
</FrameLayout>
|
||||
</org.joinmastodon.android.ui.views.TabBar>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user