Fix bottom app bar not shown in ViewRedditGalleryImageOrGifFragment.

This commit is contained in:
Docile-Alligator 2022-12-04 07:41:25 +11:00
parent 57985ed95a
commit a3ddcb874d
2 changed files with 5 additions and 4 deletions

View File

@ -228,8 +228,8 @@ public class ViewRedditGalleryImageOrGifFragment extends Fragment {
if (activity.isUseBottomAppBar()) { if (activity.isUseBottomAppBar()) {
bottomAppBarMenu.setVisibility(View.VISIBLE); bottomAppBarMenu.setVisibility(View.VISIBLE);
} }
if (captionTextOrUrlIsNotEmpty){ if (captionTextOrUrlIsNotEmpty) {
bottomAppBar.setVisibility(View.VISIBLE); captionLayout.setVisibility(View.VISIBLE);
} }
} else { } else {
hideAppBar(); hideAppBar();
@ -317,7 +317,7 @@ public class ViewRedditGalleryImageOrGifFragment extends Fragment {
captionUrlTextView.setHighlightColor(Color.TRANSPARENT); captionUrlTextView.setHighlightColor(Color.TRANSPARENT);
} }
} else { } else {
bottomAppBar.setVisibility(View.GONE); captionLayout.setVisibility(View.GONE);
} }
return rootView; return rootView;
@ -335,7 +335,7 @@ public class ViewRedditGalleryImageOrGifFragment extends Fragment {
if (activity.isUseBottomAppBar()) { if (activity.isUseBottomAppBar()) {
bottomAppBarMenu.setVisibility(View.GONE); bottomAppBarMenu.setVisibility(View.GONE);
} }
bottomAppBar.setVisibility(View.GONE); captionLayout.setVisibility(View.GONE);
} }
private void loadImage() { private void loadImage() {

View File

@ -45,6 +45,7 @@
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="bottom" android:layout_gravity="bottom"
android:minHeight="0dp"
app:paddingBottomSystemWindowInsets="false" app:paddingBottomSystemWindowInsets="false"
android:backgroundTint="#80000000"> android:backgroundTint="#80000000">