Media : start to refact renderer to be more generic

This commit is contained in:
ganfra
2019-01-23 20:29:47 +01:00
parent f9ca8f35bc
commit 7c4ac7b53a
5 changed files with 112 additions and 100 deletions

View File

@ -1,16 +1,17 @@
package im.vector.matrix.android.api.session.room.model.message
import android.media.ExifInterface
import com.squareup.moshi.Json
import com.squareup.moshi.JsonClass
@JsonClass(generateAdapter = true)
data class ImageInfo(
@Json(name = "mimetype") val mimeType: String,
@Json(name = "w") val width: Int,
@Json(name = "h") val height: Int,
@Json(name = "size") val size: Int,
@Json(name = "rotation") val rotation: Int? = null,
@Json(name = "orientation") val orientation: Int? = null,
@Json(name = "w") val width: Int = 0,
@Json(name = "h") val height: Int = 0,
@Json(name = "size") val size: Int = 0,
@Json(name = "rotation") val rotation: Int = 0,
@Json(name = "orientation") val orientation: Int = ExifInterface.ORIENTATION_NORMAL,
@Json(name = "thumbnail_info") val thumbnailInfo: ThumbnailInfo? = null,
@Json(name = "thumbnail_url") val thumbnailUrl: String? = null
)