mirror of
https://github.com/JustinZeus/Wholphin.git
synced 2026-11-06 02:40:58 +01:00
Screensaver fixes (#1047)
## Description Fixes a few issues with the in-app & OS screensavers - Make sure clock is updating for in-app screensaver - Fix crash if app is force quit before the OS screensaver starts ### Related issues Fixes #1045 ### Testing NVIDIA shield ## Screenshots N/A ## AI or LLM usage None
This commit is contained in:
parent
83ebd922d9
commit
ce44e9593b
5 changed files with 81 additions and 62 deletions
|
|
@ -153,7 +153,7 @@ fun PreferencesContent(
|
|||
try {
|
||||
System.loadLibrary("mpv")
|
||||
System.loadLibrary("player")
|
||||
} catch (ex: Exception) {
|
||||
} catch (ex: UnsatisfiedLinkError) {
|
||||
Timber.w(ex, "Could not load libmpv")
|
||||
showToast(context, "MPV is not supported on this device")
|
||||
viewModel.preferenceDataStore.updateData {
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ data class Clock(
|
|||
fun ProvideLocalClock(content: @Composable () -> Unit) {
|
||||
val clock = remember { Clock() }
|
||||
LaunchedEffect(Unit) {
|
||||
withContext(Dispatchers.IO) {
|
||||
withContext(Dispatchers.Default) {
|
||||
while (isActive) {
|
||||
val now = LocalDateTime.now()
|
||||
val time = TimeFormatter.format(now)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue