nohana / Laevatein

Photo image selection activity set library. Currently under development.
247 stars 45 forks source link

Change Picasso's resize() function to fit() #66

Closed ghost closed 6 years ago

ghost commented 6 years ago

Overview

Change Picasso's resize() function to fit()

Picasso.fit()

  /**
   * Attempt to resize the image to fit exactly into the target {@link ImageView}'s bounds. This
   * will result in delayed execution of the request until the {@link ImageView} has been laid out.
   * <p>
   * <em>Note:</em> This method works only when your target is an {@link ImageView}.
   */
  public RequestCreator fit() {
    deferred = true;
    return this;
  }

Comparison

Nexus 5X(1080 x 1920 420api)

Before(resize) After(fit)
grid before_grid resize after_grid fit
preview(max scale) before resize after fit
hiroyuki-seto commented 6 years ago

awesome