Skip to content

Instantly share code, notes, and snippets.

@fobidlim
Created March 12, 2017 16:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fobidlim/7a75b85a0159f65d8532b0c78efd17ab to your computer and use it in GitHub Desktop.
Save fobidlim/7a75b85a0159f65d8532b0c78efd17ab to your computer and use it in GitHub Desktop.
Loading image with Glide
Glide.with(MainActivity.this)
.load(IMAGE_URL)
.asBitmap()
.into(new SimpleTarget<Bitmap>() {
@Override
public void onResourceReady(Bitmap resource, GlideAnimation<? super Bitmap> glideAnimation) {
Bitmap bitmap = ImageUtils.getCircularBitmap(resource);
builder.setLargeIcon(bitmap);
NotificationManagerCompat.from(MainActivity.this)
.notify(++notificationId, builder.build());
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment