add an offline mode that stays on the downloaded library

This commit is contained in:
austinried
2026-10-04 00:30:04 +00:00
parent 92637deb48
commit 8cccee7065
18 changed files with 537 additions and 60 deletions
@@ -53,6 +53,12 @@ class SettingsViewModel(
.scrobbling()
.stateIn(viewModelScope, SharingStarted.WhileSubscribed(5_000), true)
val offline: StateFlow<Boolean> = sourceRepository.offline
fun setOfflineMode(enabled: Boolean) {
sourceRepository.setOfflineMode(enabled)
}
fun selectSource(id: Long) {
viewModelScope.launch { sourceRepository.selectSource(id) }
}