Remove unnecessary context args in slide creation.

This commit is contained in:
Greyson Parrelli
2023-08-30 12:44:23 -04:00
committed by Nicholas Tinsley
parent a911a007d2
commit b42dd5289b
15 changed files with 49 additions and 51 deletions

View File

@@ -90,7 +90,7 @@ public class MediaUtil {
}
}
public static @NonNull Slide getSlideForAttachment(Context context, Attachment attachment) {
public static @NonNull Slide getSlideForAttachment(Attachment attachment) {
if (attachment.isSticker()) {
return new StickerSlide(attachment);
}
@@ -98,12 +98,12 @@ public class MediaUtil {
switch (getSlideTypeFromContentType(attachment.getContentType())) {
case GIF : return new GifSlide(attachment);
case IMAGE : return new ImageSlide(attachment);
case VIDEO : return new VideoSlide(context, attachment);
case AUDIO : return new AudioSlide(context, attachment);
case MMS : return new MmsSlide(context, attachment);
case LONG_TEXT : return new TextSlide(context, attachment);
case VIEW_ONCE : return new ViewOnceSlide(context, attachment);
case DOCUMENT : return new DocumentSlide(context, attachment);
case VIDEO : return new VideoSlide(attachment);
case AUDIO : return new AudioSlide(attachment);
case MMS : return new MmsSlide(attachment);
case LONG_TEXT : return new TextSlide(attachment);
case VIEW_ONCE : return new ViewOnceSlide(attachment);
case DOCUMENT : return new DocumentSlide(attachment);
default : throw new AssertionError();
}
}