Add support for animated stickers.

This commit is contained in:
Greyson Parrelli
2020-09-02 12:46:58 -04:00
committed by Cody Henthorne
parent bb708e0aa3
commit f4a199f621
26 changed files with 146 additions and 72 deletions

View File

@@ -61,7 +61,6 @@ public class SignalGlideModule extends AppGlideModule {
@Override
public void applyOptions(Context context, GlideBuilder builder) {
builder.setLogLevel(Log.ERROR);
// builder.setDiskCache(new NoopDiskCacheFactory());
}
@Override

View File

@@ -22,8 +22,8 @@ public class StickerSlide extends Slide {
super(context, attachment);
}
public StickerSlide(Context context, Uri uri, long size, @NonNull StickerLocator stickerLocator) {
super(context, constructAttachmentFromUri(context, uri, MediaUtil.IMAGE_WEBP, size, WIDTH, HEIGHT, true, null, null, stickerLocator, null, null, false, false, false));
public StickerSlide(Context context, Uri uri, long size, @NonNull StickerLocator stickerLocator, @NonNull String contentType) {
super(context, constructAttachmentFromUri(context, uri, contentType, size, WIDTH, HEIGHT, true, null, null, stickerLocator, null, null, false, false, false));
}
@Override
@@ -41,6 +41,11 @@ public class StickerSlide extends Slide {
return true;
}
@Override
public boolean isBorderless() {
return true;
}
@Override
public @NonNull String getContentDescription() {
return context.getString(R.string.Slide_sticker);