mirror of
https://github.com/JustinZeus/Wholphin.git
synced 2026-07-08 23:51:21 +02:00
UI tweaks
This commit is contained in:
parent
bdfe143308
commit
8bbcd50385
4 changed files with 8 additions and 14 deletions
|
|
@ -63,17 +63,8 @@ abstract class LoadingItemViewModel<T : DolphinModel>(
|
|||
open fun init(
|
||||
itemId: UUID,
|
||||
potential: BaseItem?,
|
||||
): Job? {
|
||||
if (item.value == null && potential?.id == itemId) {
|
||||
item.value = potential
|
||||
loading.value = LoadingState.Success
|
||||
return null
|
||||
}
|
||||
if (item.value?.id == itemId) {
|
||||
loading.value = LoadingState.Success
|
||||
return null
|
||||
}
|
||||
return viewModelScope.launch(
|
||||
): Job? =
|
||||
viewModelScope.launch(
|
||||
LoadingExceptionHandler(
|
||||
loading,
|
||||
"Error loading item $itemId",
|
||||
|
|
@ -93,5 +84,4 @@ abstract class LoadingItemViewModel<T : DolphinModel>(
|
|||
loading.value = LoadingState.Error("Error loading item $itemId", e)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -207,7 +207,7 @@ fun MovieDetailsHeader(
|
|||
}
|
||||
dto.genres?.letNotEmpty {
|
||||
TitleValueText(
|
||||
stringResource(R.string.studios),
|
||||
stringResource(R.string.genres),
|
||||
it.joinToString(", "),
|
||||
modifier = Modifier.widthIn(max = 80.dp),
|
||||
)
|
||||
|
|
|
|||
|
|
@ -45,6 +45,7 @@ import androidx.media3.ui.compose.state.rememberPresentationState
|
|||
import androidx.media3.ui.compose.state.rememberPreviousButtonState
|
||||
import androidx.tv.material3.MaterialTheme
|
||||
import com.github.damontecres.dolphin.preferences.UserPreferences
|
||||
import com.github.damontecres.dolphin.ui.components.LoadingPage
|
||||
import com.github.damontecres.dolphin.ui.nav.Destination
|
||||
import com.github.damontecres.dolphin.ui.nav.NavigationManager
|
||||
import com.github.damontecres.dolphin.ui.tryRequestFocus
|
||||
|
|
@ -147,7 +148,9 @@ fun PlaybackContent(
|
|||
Modifier
|
||||
.matchParentSize()
|
||||
.background(Color.Black),
|
||||
)
|
||||
) {
|
||||
LoadingPage()
|
||||
}
|
||||
}
|
||||
|
||||
if (!controllerViewState.controlsVisible && skipIndicatorDuration != 0L) {
|
||||
|
|
|
|||
|
|
@ -41,4 +41,5 @@
|
|||
<string name="studios">Studios</string>
|
||||
<string name="video">Video</string>
|
||||
<string name="audio">Audio</string>
|
||||
<string name="genres">Genres</string>
|
||||
</resources>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue