Keep the screensaver caption on the right
Also shorten the language lookup in attachBaseContext. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
33ab0c8a66
commit
ed39d0c2a8
2 files changed
+3
-3
No files matched your search
@@ -36,8 +36,7 @@ class MainActivity : ComponentActivity() {
|
||||
|
||||
/** The interface language follows the setting, not only the system. */
|
||||
override fun attachBaseContext(newBase: Context) {
|
||||
val tag = SettingsStore(newBase).language().tag
|
||||
if (tag == null) return super.attachBaseContext(newBase)
|
||||
val tag = SettingsStore(newBase).language().tag ?: return super.attachBaseContext(newBase)
|
||||
val config = Configuration(newBase.resources.configuration)
|
||||
val locale = Locale.forLanguageTag(tag)
|
||||
Locale.setDefault(locale)
|
||||
|
||||
@@ -211,7 +211,8 @@ private fun ScreenSaver(state: AppState, track: Track, galleries: MutableMap<Lon
|
||||
)
|
||||
// The caption changes sides with each photo, so nothing sits still on the panel.
|
||||
// The lyrics ride with it, stacked right above the song name over a shade of their own.
|
||||
Crossfade(slide.n % 2 == 0, animationSpec = tween(PHOTO_FADE_MS), label = "caption") { left ->
|
||||
// always align right
|
||||
Crossfade(/*slide.n % 2 == 0*/ false, animationSpec = tween(PHOTO_FADE_MS), label = "caption") { left ->
|
||||
Box(Modifier.fillMaxSize()) {
|
||||
if (lyrics != null) {
|
||||
val shade = Color.Black.copy(alpha = 0.6f)
|
||||
|
||||
Reference in new issue
Block a user