Skip to content

Glide 4.5.0

Compare
Choose a tag to compare
@sjudd sjudd released this 05 Jan 18:53
· 848 commits to master since this release

This is the December release of Glide.

Features

  • Add an API to pause all requests for a given Activity or Fragment to allow callers to manually reduce memory when their Fragment or Application is backgrounded (@kurtisnelson, 09e33a2)
  • Fully support Bitmap re-use for RGBA_F16 Bitmaps. Previously Glide supported decoding RGBA_F16 Bitmaps, but would not re-use any stored in the BitmapPool when doing so (cc0288c)
  • Support decoding Videos from resources as AssetFileDescriptors (6e9866b)
  • Added support for the MediaMetadataRetriever#getScaledFrameAtTime method added in OMR1 to marginally reduce memory usage when decoding video frames (ded8f77)
  • Support transcoding BitmapDrawables to byte[]s (015d265)

Bugs

  • Cleaned up old and incorrect @TargetApi annoatations (@SUPERCILEX, 6778396)
  • Added @Nullable and @NonNull annotations to many of Glide's APIs (@SUPERCILEX, dc12b60, c3dafde, 0cffd1d, f541b65, 36e0b80, 650bb77, bd2f215, e35a73b, f37ced1, bb96b63, 276d4ff, c310780, )
  • Fixed a case where restarting an identical request with skipMemoryCache(true) would complete the load from the memory cache (#2663, 3dc1d18)
  • Fixed decoding interlaced and downsampled GIFs as static images (#2698, b64f23d)
  • Added more models to the list of devices requiring a lock when decoding or drawing Bitmaps (@strooooke, #738, c809f7e, e923554)
  • Fixed a race condition where starting multiple loads simultaneously the first time any request is made for a given model and resource could lead to NPEs (#2708, d427cbd)
  • Make the annotation processor tests pass on Windows (@SUPERCILEX, #2709, 2b4be8b)
  • Fix NPE and RuntimeExceptions thrown in DefaultConnectivityMonitor on some devices (c902730)
  • Only trim to half of the memory cache maximum size, not the current size, when background the app (@kurtisnelson, 429b7e2)
  • Fix a StateVerifier exception thrown when ResourceEncoder implementations unexpectedly throw exceptions while writing resources to Glide's disk cache (6c7cf3f)
  • Fix an NPE error message when ResourceDrawableDecoder fails to decode an image (d522ac7)
  • Fix an IllegalStateException if a request using .error() is cleared while the error request is running (#2767, 9c70aa5)
  • Cleaned up a number of accessor classes generated by unnecessarily strict visibility in inner classes (@TWiStErRob, e029694)
  • Updated OkHttp and removed a no longer necessary workaround for ClassCastExceptions thrown by the Android framework on O (#2355, 642b2dc)
  • Added missing annotations to overrides on some of Glide's generated classes (@TWiStErRob, 62d7464, 9fde006, d7bb6f9)
  • Avoid throwing exceptions when LruBitmapPool was asked to provide Bitmaps with a null config (c1036c1)

Behavior Changes

  • Default to aar packaging in POMs, so @aar should no longer be required to avoid warnings about jars depending on aars (06ba344)
  • Default active resource retention to false (73759b9), but leave the option in GlideBuilder to manually enable it. Enabling active resource retention can lead to recycled Bitmap errors or Bitmap re-use bugs if applications call Bitmap.recycle() on any images loaded by Glide or mutate the contents of Bitmaps loaded by Glide.
  • Treat devices with API < 19 as having ActivityManager.isLowRam set to true (#2650, b221d4b)

Breaking Changes

  • Removed deprecated constructors requiring Contexts in most of Glide's default Transformation (23975d9, 733b2e0, 9bedc2b, 55594ba, d8f6224, d840533, 2f76842, 144ac53, 150ebab, 92d761d, a6f1b1c)
  • The @NonNull and @Nullable annotations added in this release may break builds that depend on compiler plugins that do static nullability analysis, typically due a lack of annotations on any implemenations you might have of Glide's interfaces.

Deprecations

Build Changes