Fix some images not showing in center.

This commit is contained in:
Alex Ning 2021-01-07 15:59:45 +08:00
parent 2f912a523e
commit df18fc63ad
3 changed files with 3 additions and 0 deletions

View File

@ -223,6 +223,7 @@ public class ViewImageOrGifActivity extends AppCompatActivity implements SetAsWa
view.setDoubleTapZoomDpi(240);
view.setDoubleTapZoomStyle(SubsamplingScaleImageView.ZOOM_FOCUS_FIXED);
view.setQuickScaleEnabled(true);
view.resetScaleAndCenter();
}
@Override

View File

@ -104,6 +104,7 @@ public class ViewImgurImageFragment extends Fragment {
});
imageView.setMinimumDpi(80);
imageView.setDoubleTapZoomDpi(240);
imageView.resetScaleAndCenter();
errorLinearLayout.setOnClickListener(view -> {
progressBar.setVisibility(View.VISIBLE);

View File

@ -141,6 +141,7 @@ public class ViewRedditGalleryImageOrGifFragment extends Fragment {
view.setDoubleTapZoomDpi(240);
view.setDoubleTapZoomStyle(SubsamplingScaleImageView.ZOOM_FOCUS_FIXED);
view.setQuickScaleEnabled(true);
view.resetScaleAndCenter();
}
@Override