mirror of
https://github.com/JustinZeus/Wholphin.git
synced 2026-07-09 08:01:20 +02:00
Update jellyfin-sdk-kotlin
This commit is contained in:
parent
9e7742034a
commit
40310c8442
6 changed files with 13 additions and 10 deletions
|
|
@ -33,7 +33,6 @@ import kotlinx.serialization.json.jsonPrimitive
|
||||||
import okhttp3.OkHttpClient
|
import okhttp3.OkHttpClient
|
||||||
import okhttp3.Request
|
import okhttp3.Request
|
||||||
import okhttp3.Response
|
import okhttp3.Response
|
||||||
import okhttp3.internal.headersContentLength
|
|
||||||
import timber.log.Timber
|
import timber.log.Timber
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import java.io.InputStream
|
import java.io.InputStream
|
||||||
|
|
@ -211,7 +210,7 @@ class UpdateChecker
|
||||||
if (it.isSuccessful && it.body != null) {
|
if (it.isSuccessful && it.body != null) {
|
||||||
Timber.v("Request successful for ${release.downloadUrl}")
|
Timber.v("Request successful for ${release.downloadUrl}")
|
||||||
withContext(Dispatchers.Main) {
|
withContext(Dispatchers.Main) {
|
||||||
callback.contentLength(it.headersContentLength())
|
callback.contentLength(it.body.contentLength())
|
||||||
}
|
}
|
||||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q) {
|
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q) {
|
||||||
val contentValues =
|
val contentValues =
|
||||||
|
|
|
||||||
|
|
@ -268,6 +268,7 @@ fun formatVideoRange(
|
||||||
when (type) {
|
when (type) {
|
||||||
VideoRangeType.UNKNOWN,
|
VideoRangeType.UNKNOWN,
|
||||||
VideoRangeType.SDR,
|
VideoRangeType.SDR,
|
||||||
|
VideoRangeType.DOVI_INVALID,
|
||||||
null,
|
null,
|
||||||
-> null
|
-> null
|
||||||
|
|
||||||
|
|
@ -281,6 +282,9 @@ fun formatVideoRange(
|
||||||
VideoRangeType.DOVI_WITH_HDR10,
|
VideoRangeType.DOVI_WITH_HDR10,
|
||||||
VideoRangeType.DOVI_WITH_HLG,
|
VideoRangeType.DOVI_WITH_HLG,
|
||||||
VideoRangeType.DOVI_WITH_SDR,
|
VideoRangeType.DOVI_WITH_SDR,
|
||||||
|
VideoRangeType.DOVI_WITH_EL,
|
||||||
|
VideoRangeType.DOVI_WITH_HDR10_PLUS,
|
||||||
|
VideoRangeType.DOVI_WITH_ELHDR10_PLUS,
|
||||||
-> context.getString(R.string.dolby_vision)
|
-> context.getString(R.string.dolby_vision)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,13 +1,13 @@
|
||||||
package com.github.damontecres.wholphin.ui.playback
|
package com.github.damontecres.wholphin.ui.playback
|
||||||
|
|
||||||
import com.github.damontecres.wholphin.data.model.Chapter
|
import com.github.damontecres.wholphin.data.model.Chapter
|
||||||
import org.jellyfin.sdk.model.api.TrickplayInfo
|
import org.jellyfin.sdk.model.api.TrickplayInfoDto
|
||||||
|
|
||||||
data class CurrentMediaInfo(
|
data class CurrentMediaInfo(
|
||||||
val audioStreams: List<AudioStream>,
|
val audioStreams: List<AudioStream>,
|
||||||
val subtitleStreams: List<SubtitleStream>,
|
val subtitleStreams: List<SubtitleStream>,
|
||||||
val chapters: List<Chapter>,
|
val chapters: List<Chapter>,
|
||||||
val trickPlayInfo: TrickplayInfo?,
|
val trickPlayInfo: TrickplayInfoDto?,
|
||||||
) {
|
) {
|
||||||
companion object {
|
companion object {
|
||||||
val EMPTY = CurrentMediaInfo(listOf(), listOf(), listOf(), null)
|
val EMPTY = CurrentMediaInfo(listOf(), listOf(), listOf(), null)
|
||||||
|
|
|
||||||
|
|
@ -65,7 +65,7 @@ import kotlinx.coroutines.delay
|
||||||
import kotlinx.coroutines.isActive
|
import kotlinx.coroutines.isActive
|
||||||
import org.jellyfin.sdk.model.api.ImageType
|
import org.jellyfin.sdk.model.api.ImageType
|
||||||
import org.jellyfin.sdk.model.api.MediaSegmentDto
|
import org.jellyfin.sdk.model.api.MediaSegmentDto
|
||||||
import org.jellyfin.sdk.model.api.TrickplayInfo
|
import org.jellyfin.sdk.model.api.TrickplayInfoDto
|
||||||
import java.time.LocalTime
|
import java.time.LocalTime
|
||||||
import kotlin.time.Duration
|
import kotlin.time.Duration
|
||||||
import kotlin.time.Duration.Companion.milliseconds
|
import kotlin.time.Duration.Companion.milliseconds
|
||||||
|
|
@ -98,7 +98,7 @@ fun PlaybackOverlay(
|
||||||
currentPlayback: CurrentPlayback?,
|
currentPlayback: CurrentPlayback?,
|
||||||
currentSegment: MediaSegmentDto?,
|
currentSegment: MediaSegmentDto?,
|
||||||
modifier: Modifier = Modifier,
|
modifier: Modifier = Modifier,
|
||||||
trickplayInfo: TrickplayInfo? = null,
|
trickplayInfo: TrickplayInfoDto? = null,
|
||||||
trickplayUrlFor: (Int) -> String? = { null },
|
trickplayUrlFor: (Int) -> String? = { null },
|
||||||
playlist: Playlist = Playlist(listOf(), 0),
|
playlist: Playlist = Playlist(listOf(), 0),
|
||||||
onClickPlaylist: (BaseItem) -> Unit = {},
|
onClickPlaylist: (BaseItem) -> Unit = {},
|
||||||
|
|
|
||||||
|
|
@ -20,7 +20,7 @@ import coil3.request.ImageRequest
|
||||||
import coil3.request.transformations
|
import coil3.request.transformations
|
||||||
import com.github.damontecres.wholphin.ui.CoilTrickplayTransformation
|
import com.github.damontecres.wholphin.ui.CoilTrickplayTransformation
|
||||||
import com.github.damontecres.wholphin.ui.isNotNullOrBlank
|
import com.github.damontecres.wholphin.ui.isNotNullOrBlank
|
||||||
import org.jellyfin.sdk.model.api.TrickplayInfo
|
import org.jellyfin.sdk.model.api.TrickplayInfoDto
|
||||||
|
|
||||||
fun Modifier.offsetByPercent(
|
fun Modifier.offsetByPercent(
|
||||||
xPercentage: Float,
|
xPercentage: Float,
|
||||||
|
|
@ -74,7 +74,7 @@ fun SeekPreviewImage(
|
||||||
seekProgressMs: Long,
|
seekProgressMs: Long,
|
||||||
videoWidth: Int?,
|
videoWidth: Int?,
|
||||||
videoHeight: Int?,
|
videoHeight: Int?,
|
||||||
trickPlayInfo: TrickplayInfo,
|
trickPlayInfo: TrickplayInfoDto,
|
||||||
modifier: Modifier = Modifier,
|
modifier: Modifier = Modifier,
|
||||||
placeHolder: Painter? = null,
|
placeHolder: Painter? = null,
|
||||||
) {
|
) {
|
||||||
|
|
|
||||||
|
|
@ -21,14 +21,14 @@ lifecycleRuntimeKtx = "2.10.0"
|
||||||
activityCompose = "1.12.1"
|
activityCompose = "1.12.1"
|
||||||
androidx-media3 = "1.8.0"
|
androidx-media3 = "1.8.0"
|
||||||
coil = "3.3.0"
|
coil = "3.3.0"
|
||||||
jellyfin-sdk = "1.7.1"
|
jellyfin-sdk = "1.8.4"
|
||||||
nav3Core = "1.0.0"
|
nav3Core = "1.0.0"
|
||||||
lifecycleViewmodelNav3 = "2.10.0"
|
lifecycleViewmodelNav3 = "2.10.0"
|
||||||
material3AdaptiveNav3 = "1.0.0-alpha03"
|
material3AdaptiveNav3 = "1.0.0-alpha03"
|
||||||
protobuf = "0.9.5"
|
protobuf = "0.9.5"
|
||||||
datastore = "1.2.0"
|
datastore = "1.2.0"
|
||||||
kotlinx-serialization = "1.9.0"
|
kotlinx-serialization = "1.9.0"
|
||||||
protobuf-javalite = "4.33.1"
|
protobuf-javalite = "4.33.2"
|
||||||
hilt = "2.57.2"
|
hilt = "2.57.2"
|
||||||
room = "2.8.4"
|
room = "2.8.4"
|
||||||
preferenceKtx = "1.2.1"
|
preferenceKtx = "1.2.1"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue