Small changes in RedditGallerySubmissionRecyclerViewAdapter's UI.

This commit is contained in:
Alex Ning 2021-07-16 08:56:47 +08:00
parent a610be7d16
commit 25d8d901ad
3 changed files with 17 additions and 7 deletions

View File

@ -155,8 +155,9 @@ public class RedditGallerySubmissionRecyclerViewAdapter extends RecyclerView.Ada
public AddImageViewHolder(@NonNull View itemView) { public AddImageViewHolder(@NonNull View itemView) {
super(itemView); super(itemView);
itemView.setBackgroundTintList(ColorStateList.valueOf(customThemeWrapper.getColorPrimaryLightTheme())); FloatingActionButton fab = itemView.findViewById(R.id.fab_item_gallery_submission_add_image);
((FloatingActionButton) itemView).setImageTintList(ColorStateList.valueOf(customThemeWrapper.getFABIconColor())); fab.setBackgroundTintList(ColorStateList.valueOf(customThemeWrapper.getColorPrimaryLightTheme()));
fab.setImageTintList(ColorStateList.valueOf(customThemeWrapper.getFABIconColor()));
itemView.setOnClickListener(view -> itemClickListener.onAddImageClicked()); itemView.setOnClickListener(view -> itemClickListener.onAddImageClicked());
} }

View File

@ -1,5 +1,13 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<com.google.android.material.floatingactionbutton.FloatingActionButton xmlns:android="http://schemas.android.com/apk/res/android" <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="wrap_content" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="match_parent">
android:src="@drawable/ic_outline_select_photo_24dp" />
<com.google.android.material.floatingactionbutton.FloatingActionButton
android:id="@+id/fab_item_gallery_submission_add_image"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:src="@drawable/ic_outline_select_photo_24dp" />
</LinearLayout>

View File

@ -6,7 +6,8 @@
<ml.docilealligator.infinityforreddit.customviews.AspectRatioGifImageView <ml.docilealligator.infinityforreddit.customviews.AspectRatioGifImageView
android:id="@+id/aspect_ratio_gif_image_view_item_reddit_gallery_submission_image" android:id="@+id/aspect_ratio_gif_image_view_item_reddit_gallery_submission_image"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" /> android:layout_height="wrap_content"
android:scaleType="centerCrop" />
<ProgressBar <ProgressBar
android:id="@+id/progress_bar_item_reddit_gallery_submission_image" android:id="@+id/progress_bar_item_reddit_gallery_submission_image"