From 51d7965527d16662499817ff3ab5849c3a8d42b4 Mon Sep 17 00:00:00 2001 From: Alex Ning Date: Sun, 2 Feb 2020 17:48:25 +0800 Subject: Fix fab jumps to top-left of the screen. Add more items in the bottom app bar. Add a bottom app bar in ViewSubredditDetailActivity. --- app/src/main/res/layout/activity_main.xml | 4 +- .../res/layout/activity_view_subreddit_detail.xml | 78 +++++++++++++++++++++- app/src/main/res/layout/app_bar_main.xml | 44 +++++++++--- 3 files changed, 113 insertions(+), 13 deletions(-) (limited to 'app/src/main/res/layout') diff --git a/app/src/main/res/layout/activity_main.xml b/app/src/main/res/layout/activity_main.xml index cf48f84e..ba6cc170 100644 --- a/app/src/main/res/layout/activity_main.xml +++ b/app/src/main/res/layout/activity_main.xml @@ -64,7 +64,7 @@ android:layout_height="24dp" android:layout_gravity="center_vertical" android:layout_marginEnd="32dp" - android:src="@drawable/ic_outline_account_circle_24px" + android:src="@drawable/ic_account_circle_24dp" android:tint="@color/primaryTextColor"/> + + + + + + + + + + + + + + + + + + app:layout_anchor="@id/bottom_navigation_view_subreddit_detail_activity" /> \ No newline at end of file diff --git a/app/src/main/res/layout/app_bar_main.xml b/app/src/main/res/layout/app_bar_main.xml index a9008a36..e81f6f7b 100644 --- a/app/src/main/res/layout/app_bar_main.xml +++ b/app/src/main/res/layout/app_bar_main.xml @@ -69,16 +69,29 @@ android:id="@+id/linear_layout_bottom_app_bar_main_activity" android:layout_width="match_parent" android:layout_height="wrap_content" - android:weightSum="3"> + android:weightSum="5"> - + + @@ -88,17 +101,30 @@ android:layout_weight="1" android:background="@android:color/transparent"/> - + + + android:background="?attr/selectableItemBackgroundBorderless" /> -- cgit v1.2.3