Skip to content

Commit

Permalink
Fix explicit type warnings
Browse files Browse the repository at this point in the history
Reviewed By: oprisnik

Differential Revision: D54851734

fbshipit-source-id: f63318b3cacdc74e5ceba9597291ab5e5d9c3873
  • Loading branch information
Artem Kholodnyi authored and facebook-github-bot committed Mar 14, 2024
1 parent c614f1f commit 6d1af66
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,18 +9,19 @@ package com.facebook.imageformat

/** Default image formats that Fresco supports. */
object DefaultImageFormats {
@JvmField val JPEG = ImageFormat("JPEG", "jpeg")
@JvmField val PNG = ImageFormat("PNG", "png")
@JvmField val GIF = ImageFormat("GIF", "gif")
@JvmField val BMP = ImageFormat("BMP", "bmp")
@JvmField val ICO = ImageFormat("ICO", "ico")
@JvmField val WEBP_SIMPLE = ImageFormat("WEBP_SIMPLE", "webp")
@JvmField val WEBP_LOSSLESS = ImageFormat("WEBP_LOSSLESS", "webp")
@JvmField val WEBP_EXTENDED = ImageFormat("WEBP_EXTENDED", "webp")
@JvmField val WEBP_EXTENDED_WITH_ALPHA = ImageFormat("WEBP_EXTENDED_WITH_ALPHA", "webp")
@JvmField val WEBP_ANIMATED = ImageFormat("WEBP_ANIMATED", "webp")
@JvmField val HEIF = ImageFormat("HEIF", "heif")
@JvmField val DNG = ImageFormat("DNG", "dng")
@JvmField val JPEG: ImageFormat = ImageFormat("JPEG", "jpeg")
@JvmField val PNG: ImageFormat = ImageFormat("PNG", "png")
@JvmField val GIF: ImageFormat = ImageFormat("GIF", "gif")
@JvmField val BMP: ImageFormat = ImageFormat("BMP", "bmp")
@JvmField val ICO: ImageFormat = ImageFormat("ICO", "ico")
@JvmField val WEBP_SIMPLE: ImageFormat = ImageFormat("WEBP_SIMPLE", "webp")
@JvmField val WEBP_LOSSLESS: ImageFormat = ImageFormat("WEBP_LOSSLESS", "webp")
@JvmField val WEBP_EXTENDED: ImageFormat = ImageFormat("WEBP_EXTENDED", "webp")
@JvmField
val WEBP_EXTENDED_WITH_ALPHA: ImageFormat = ImageFormat("WEBP_EXTENDED_WITH_ALPHA", "webp")
@JvmField val WEBP_ANIMATED: ImageFormat = ImageFormat("WEBP_ANIMATED", "webp")
@JvmField val HEIF: ImageFormat = ImageFormat("HEIF", "heif")
@JvmField val DNG: ImageFormat = ImageFormat("DNG", "dng")

/**
* Check if the given image format is a WebP image format (static or animated).
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,6 @@ data class ImageFormat(

companion object {
// Unknown image format
@JvmField val UNKNOWN = ImageFormat("UNKNOWN", null)
@JvmField val UNKNOWN: ImageFormat = ImageFormat("UNKNOWN", null)
}
}

0 comments on commit 6d1af66

Please sign in to comment.