From 4ab8f037f2b3da61a11b46f547615be3d2aab77f Mon Sep 17 00:00:00 2001 From: Alex Ning Date: Sat, 30 Oct 2021 21:20:48 +0800 Subject: Start migrating to Material Design 3. Try optimizing image loading in PostRecyclerViewAdapter. --- .../res/layout/activity_view_subreddit_detail.xml | 2 +- .../main/res/layout/activity_view_user_detail.xml | 2 +- app/src/main/res/layout/activity_view_video.xml | 1 + app/src/main/res/layout/app_bar_main.xml | 2 +- app/src/main/res/layout/item_post_with_preview.xml | 36 ++++++++-------------- 5 files changed, 17 insertions(+), 26 deletions(-) (limited to 'app/src/main/res/layout') diff --git a/app/src/main/res/layout/activity_view_subreddit_detail.xml b/app/src/main/res/layout/activity_view_subreddit_detail.xml index bdb46784..6709af9f 100644 --- a/app/src/main/res/layout/activity_view_subreddit_detail.xml +++ b/app/src/main/res/layout/activity_view_subreddit_detail.xml @@ -140,7 +140,7 @@ - - diff --git a/app/src/main/res/layout/app_bar_main.xml b/app/src/main/res/layout/app_bar_main.xml index 9aef7ff3..fe3656be 100644 --- a/app/src/main/res/layout/app_bar_main.xml +++ b/app/src/main/res/layout/app_bar_main.xml @@ -21,7 +21,7 @@ app:titleEnabled="false" app:toolbarId="@+id/toolbar"> - - @@ -233,29 +232,20 @@ android:id="@+id/progress_bar_item_post_with_preview" android:layout_width="wrap_content" android:layout_height="wrap_content" - android:layout_centerInParent="true" /> + android:layout_gravity="center" /> - - - - - - - + android:layout_height="wrap_content" + android:drawableTop="@drawable/ic_error_outline_black_24dp" + android:layout_gravity="center" + android:gravity="center" + android:text="@string/error_loading_image_tap_to_retry" + android:textSize="?attr/font_default" + android:fontFamily="?attr/font_family" /> + +