diff --git a/android/app/build.gradle.kts b/android/app/build.gradle.kts index 498837cc..cd6f66f3 100644 --- a/android/app/build.gradle.kts +++ b/android/app/build.gradle.kts @@ -3,7 +3,7 @@ plugins { id("org.jetbrains.kotlin.plugin.compose") } /** The release's build number: versionCode is this x 10 plus the edition's channel. */ -val ORBIT_BUILD = 59 +val ORBIT_BUILD = 60 android { namespace = "tv.orbit.classic" compileSdk = 36 diff --git a/android/app/src/main/java/tv/orbit/classic/ChannelBranding.kt b/android/app/src/main/java/tv/orbit/classic/ChannelBranding.kt index 210c2b45..3c767e66 100644 --- a/android/app/src/main/java/tv/orbit/classic/ChannelBranding.kt +++ b/android/app/src/main/java/tv/orbit/classic/ChannelBranding.kt @@ -4,6 +4,7 @@ import androidx.compose.foundation.layout.offset import androidx.compose.runtime.getValue import androidx.compose.runtime.setValue import androidx.compose.ui.unit.dp +import androidx.compose.ui.draw.alpha internal data class ChannelBranding(val presetId: String, val displayName: String, val logo: Int, val background: Int, val bug: Int, val category: ChannelCategory) @@ -91,3 +92,62 @@ internal fun cornerLogoOffset(nowMs: Long): Pair = when (Math.floorMod 2 -> 3 to -3 else -> 0 to -3 } + +/** Each channel's corner animation: its planet arriving in the brand brief's motion, then the logo, on transparent. */ +private val CornerAnimations: Map = mapOf( + 101 to R.raw.corner_anim_101, 102 to R.raw.corner_anim_102, 103 to R.raw.corner_anim_103, 104 to R.raw.corner_anim_104, 105 to R.raw.corner_anim_105, 106 to R.raw.corner_anim_106, + 107 to R.raw.corner_anim_107, 108 to R.raw.corner_anim_108, 109 to R.raw.corner_anim_109, 110 to R.raw.corner_anim_110, 201 to R.raw.corner_anim_201, 202 to R.raw.corner_anim_202, + 203 to R.raw.corner_anim_203, 204 to R.raw.corner_anim_204, 205 to R.raw.corner_anim_205, 206 to R.raw.corner_anim_206, 300 to R.raw.corner_anim_300, 301 to R.raw.corner_anim_301, + 302 to R.raw.corner_anim_302, 303 to R.raw.corner_anim_303, 304 to R.raw.corner_anim_304, 305 to R.raw.corner_anim_305, 306 to R.raw.corner_anim_306, 307 to R.raw.corner_anim_307, + 308 to R.raw.corner_anim_308, 309 to R.raw.corner_anim_309, 310 to R.raw.corner_anim_310, 401 to R.raw.corner_anim_401, 601 to R.raw.corner_anim_601, 602 to R.raw.corner_anim_602, + 603 to R.raw.corner_anim_603, 604 to R.raw.corner_anim_604, 605 to R.raw.corner_anim_605, 611 to R.raw.corner_anim_611, 612 to R.raw.corner_anim_612, 613 to R.raw.corner_anim_613, + 614 to R.raw.corner_anim_614) +private val PackCornerAnimations: Map = mapOf("orbit-mistletoe" to R.raw.corner_anim_mistletoe, "orbit-sakura" to R.raw.corner_anim_sakura) +internal fun cornerAnimation(number: Int): Int? = CornerAnimations[number] ?: CustomChannels.of(number)?.brand?.let { PackCornerAnimations[it] } + +/** + * Whether the corner logo plays its animation now (Paul, 17 November 2026: "shown on bottom left every like hour"): once + * in the first two minutes of each hour, the first time the logo is up then. + */ +internal fun cornerAnimationDue(nowMs: Long, lastPlayedHour: Long): Boolean { + val hour = nowMs / 3_600_000L + return hour != lastPlayedHour && nowMs % 3_600_000L < 120_000L +} + +private object CornerAnimationClock { var lastPlayedHour = -1L } + +/** How long the corner animation runs before the still logo takes over again. */ +internal const val CORNER_ANIMATION_MS = 3_400L + +/** + * The corner logo: the white still at 60% (see [cornerLogoNudge]), and about once an hour the channel's animation in its + * colours, which then hands back to the still. Reduce motion keeps the still. Needs Android 9 for animated images. + */ +@androidx.compose.runtime.Composable +internal fun CornerLogo(number: Int, still: Int, modifier: androidx.compose.ui.Modifier) { + val context = androidx.compose.ui.platform.LocalContext.current + val calm = androidx.compose.runtime.remember { OrbitSettings(context).reduceMotion } + val animation = androidx.compose.runtime.remember(number) { cornerAnimation(number) } + var playing by androidx.compose.runtime.remember { androidx.compose.runtime.mutableStateOf(false) } + androidx.compose.runtime.LaunchedEffect(number, animation) { + if (animation == null || calm || android.os.Build.VERSION.SDK_INT < 28) return@LaunchedEffect + while (true) { + val now = System.currentTimeMillis() + if (cornerAnimationDue(now, CornerAnimationClock.lastPlayedHour)) { + CornerAnimationClock.lastPlayedHour = now / 3_600_000L + playing = true; kotlinx.coroutines.delay(CORNER_ANIMATION_MS); playing = false + } + kotlinx.coroutines.delay(5_000) + } + } + if (playing && animation != null && android.os.Build.VERSION.SDK_INT >= 28) + androidx.compose.ui.viewinterop.AndroidView(modifier = modifier.alpha(.85f), factory = { c -> + android.widget.ImageView(c).apply { + scaleType = android.widget.ImageView.ScaleType.FIT_START + val drawable = android.graphics.ImageDecoder.decodeDrawable(android.graphics.ImageDecoder.createSource(c.resources, animation)) + setImageDrawable(drawable) + (drawable as? android.graphics.drawable.AnimatedImageDrawable)?.apply { repeatCount = 0; start() } + } + }) + else androidx.compose.foundation.Image(cachedPainter(still), null, modifier, alpha = .6f) +} diff --git a/android/app/src/main/java/tv/orbit/classic/EmbyPlaybackDialog.kt b/android/app/src/main/java/tv/orbit/classic/EmbyPlaybackDialog.kt index 8360496f..98e2540a 100644 --- a/android/app/src/main/java/tv/orbit/classic/EmbyPlaybackDialog.kt +++ b/android/app/src/main/java/tv/orbit/classic/EmbyPlaybackDialog.kt @@ -615,7 +615,7 @@ internal fun EmbyPlaybackDialog(session: EmbySampleSession, plan: EmbyPlaybackPl else if (bug != null && ready && !infoVisible && failure == null && squeeze == 0f) // The brand kit's corner logo (17 November 2026): white at 60%, bottom left with a 72 px margin, nudged a few // pixels every ten minutes so it never sits still long enough to mark an OLED or plasma screen. - Image(cachedPainter(bug), null, Modifier.align(Alignment.BottomStart).cornerLogoNudge().padding(start = 36.dp, bottom = 36.dp).height(47.dp).width(122.dp), alpha = .6f) + CornerLogo(scheduled!!.channel.number, bug, Modifier.align(Alignment.BottomStart).cornerLogoNudge().padding(start = 36.dp, bottom = 36.dp).height(47.dp).width(122.dp)) // The bar and the subtitles and sound panel together (design/watching): the panel docks above the bar's right // end, so it never hangs over it, and the bar stays while the panel is open. val barUp = (infoVisible || trackMenu != null) && failure == null && ready && squeeze == 0f diff --git a/android/app/src/main/res/raw/corner_anim_101.webp b/android/app/src/main/res/raw/corner_anim_101.webp new file mode 100644 index 00000000..d6f1b271 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_101.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_102.webp b/android/app/src/main/res/raw/corner_anim_102.webp new file mode 100644 index 00000000..8f4eab3c Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_102.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_103.webp b/android/app/src/main/res/raw/corner_anim_103.webp new file mode 100644 index 00000000..1e4de454 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_103.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_104.webp b/android/app/src/main/res/raw/corner_anim_104.webp new file mode 100644 index 00000000..f5bded44 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_104.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_105.webp b/android/app/src/main/res/raw/corner_anim_105.webp new file mode 100644 index 00000000..6fdbee77 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_105.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_106.webp b/android/app/src/main/res/raw/corner_anim_106.webp new file mode 100644 index 00000000..f36d644e Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_106.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_107.webp b/android/app/src/main/res/raw/corner_anim_107.webp new file mode 100644 index 00000000..fc92d08f Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_107.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_108.webp b/android/app/src/main/res/raw/corner_anim_108.webp new file mode 100644 index 00000000..b207099c Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_108.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_109.webp b/android/app/src/main/res/raw/corner_anim_109.webp new file mode 100644 index 00000000..f85bb62f Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_109.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_110.webp b/android/app/src/main/res/raw/corner_anim_110.webp new file mode 100644 index 00000000..a683bf81 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_110.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_201.webp b/android/app/src/main/res/raw/corner_anim_201.webp new file mode 100644 index 00000000..08c1306d Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_201.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_202.webp b/android/app/src/main/res/raw/corner_anim_202.webp new file mode 100644 index 00000000..2a22c5cc Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_202.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_203.webp b/android/app/src/main/res/raw/corner_anim_203.webp new file mode 100644 index 00000000..c89528b0 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_203.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_204.webp b/android/app/src/main/res/raw/corner_anim_204.webp new file mode 100644 index 00000000..80fdbd59 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_204.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_205.webp b/android/app/src/main/res/raw/corner_anim_205.webp new file mode 100644 index 00000000..948d8295 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_205.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_206.webp b/android/app/src/main/res/raw/corner_anim_206.webp new file mode 100644 index 00000000..66d6ee0d Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_206.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_300.webp b/android/app/src/main/res/raw/corner_anim_300.webp new file mode 100644 index 00000000..85f85749 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_300.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_301.webp b/android/app/src/main/res/raw/corner_anim_301.webp new file mode 100644 index 00000000..f0081146 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_301.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_302.webp b/android/app/src/main/res/raw/corner_anim_302.webp new file mode 100644 index 00000000..10626e70 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_302.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_303.webp b/android/app/src/main/res/raw/corner_anim_303.webp new file mode 100644 index 00000000..3bcec61d Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_303.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_304.webp b/android/app/src/main/res/raw/corner_anim_304.webp new file mode 100644 index 00000000..6b44cdc5 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_304.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_305.webp b/android/app/src/main/res/raw/corner_anim_305.webp new file mode 100644 index 00000000..7d09de10 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_305.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_306.webp b/android/app/src/main/res/raw/corner_anim_306.webp new file mode 100644 index 00000000..8c8f969c Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_306.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_307.webp b/android/app/src/main/res/raw/corner_anim_307.webp new file mode 100644 index 00000000..45a7bce5 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_307.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_308.webp b/android/app/src/main/res/raw/corner_anim_308.webp new file mode 100644 index 00000000..5ea6bb86 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_308.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_309.webp b/android/app/src/main/res/raw/corner_anim_309.webp new file mode 100644 index 00000000..76c165c1 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_309.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_310.webp b/android/app/src/main/res/raw/corner_anim_310.webp new file mode 100644 index 00000000..ea03bae2 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_310.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_401.webp b/android/app/src/main/res/raw/corner_anim_401.webp new file mode 100644 index 00000000..c1b80c9a Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_401.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_601.webp b/android/app/src/main/res/raw/corner_anim_601.webp new file mode 100644 index 00000000..3db2de4c Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_601.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_602.webp b/android/app/src/main/res/raw/corner_anim_602.webp new file mode 100644 index 00000000..a312927b Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_602.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_603.webp b/android/app/src/main/res/raw/corner_anim_603.webp new file mode 100644 index 00000000..098994f2 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_603.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_604.webp b/android/app/src/main/res/raw/corner_anim_604.webp new file mode 100644 index 00000000..1e3b2a6a Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_604.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_605.webp b/android/app/src/main/res/raw/corner_anim_605.webp new file mode 100644 index 00000000..06f52ad8 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_605.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_611.webp b/android/app/src/main/res/raw/corner_anim_611.webp new file mode 100644 index 00000000..cba99fcf Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_611.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_612.webp b/android/app/src/main/res/raw/corner_anim_612.webp new file mode 100644 index 00000000..60157b03 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_612.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_613.webp b/android/app/src/main/res/raw/corner_anim_613.webp new file mode 100644 index 00000000..39273854 Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_613.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_614.webp b/android/app/src/main/res/raw/corner_anim_614.webp new file mode 100644 index 00000000..7368713c Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_614.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_mistletoe.webp b/android/app/src/main/res/raw/corner_anim_mistletoe.webp new file mode 100644 index 00000000..aed8a62d Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_mistletoe.webp differ diff --git a/android/app/src/main/res/raw/corner_anim_sakura.webp b/android/app/src/main/res/raw/corner_anim_sakura.webp new file mode 100644 index 00000000..264005ca Binary files /dev/null and b/android/app/src/main/res/raw/corner_anim_sakura.webp differ diff --git a/android/app/src/main/res/raw/ident_101.mp4 b/android/app/src/main/res/raw/ident_101.mp4 index 105db319..6a147bcc 100644 Binary files a/android/app/src/main/res/raw/ident_101.mp4 and b/android/app/src/main/res/raw/ident_101.mp4 differ diff --git a/android/app/src/main/res/raw/ident_102.mp4 b/android/app/src/main/res/raw/ident_102.mp4 index 13ed49d2..402b7fbb 100644 Binary files a/android/app/src/main/res/raw/ident_102.mp4 and b/android/app/src/main/res/raw/ident_102.mp4 differ diff --git a/android/app/src/main/res/raw/ident_103.mp4 b/android/app/src/main/res/raw/ident_103.mp4 index 408e7b7a..72bd8b8f 100644 Binary files a/android/app/src/main/res/raw/ident_103.mp4 and b/android/app/src/main/res/raw/ident_103.mp4 differ diff --git a/android/app/src/main/res/raw/ident_104.mp4 b/android/app/src/main/res/raw/ident_104.mp4 index dc33f6d3..7432a639 100644 Binary files a/android/app/src/main/res/raw/ident_104.mp4 and b/android/app/src/main/res/raw/ident_104.mp4 differ diff --git a/android/app/src/main/res/raw/ident_106.mp4 b/android/app/src/main/res/raw/ident_106.mp4 index 7b7d6962..eb216365 100644 Binary files a/android/app/src/main/res/raw/ident_106.mp4 and b/android/app/src/main/res/raw/ident_106.mp4 differ diff --git a/android/app/src/main/res/raw/ident_107.mp4 b/android/app/src/main/res/raw/ident_107.mp4 index 917de48f..546a7ea9 100644 Binary files a/android/app/src/main/res/raw/ident_107.mp4 and b/android/app/src/main/res/raw/ident_107.mp4 differ diff --git a/android/app/src/main/res/raw/ident_201.mp4 b/android/app/src/main/res/raw/ident_201.mp4 index 45ace9c4..72e92aaa 100644 Binary files a/android/app/src/main/res/raw/ident_201.mp4 and b/android/app/src/main/res/raw/ident_201.mp4 differ diff --git a/android/app/src/main/res/raw/ident_202.mp4 b/android/app/src/main/res/raw/ident_202.mp4 index eb42f6a4..2192ac8c 100644 Binary files a/android/app/src/main/res/raw/ident_202.mp4 and b/android/app/src/main/res/raw/ident_202.mp4 differ diff --git a/android/app/src/main/res/raw/ident_203.mp4 b/android/app/src/main/res/raw/ident_203.mp4 index 6bfe09a0..b2fe6f79 100644 Binary files a/android/app/src/main/res/raw/ident_203.mp4 and b/android/app/src/main/res/raw/ident_203.mp4 differ diff --git a/android/app/src/main/res/raw/ident_204.mp4 b/android/app/src/main/res/raw/ident_204.mp4 index 84b84aae..dcb0268e 100644 Binary files a/android/app/src/main/res/raw/ident_204.mp4 and b/android/app/src/main/res/raw/ident_204.mp4 differ diff --git a/android/app/src/main/res/raw/ident_301.mp4 b/android/app/src/main/res/raw/ident_301.mp4 index d5a5e052..b5044d4e 100644 Binary files a/android/app/src/main/res/raw/ident_301.mp4 and b/android/app/src/main/res/raw/ident_301.mp4 differ diff --git a/android/app/src/main/res/raw/ident_302.mp4 b/android/app/src/main/res/raw/ident_302.mp4 index 95b01b28..85462b19 100644 Binary files a/android/app/src/main/res/raw/ident_302.mp4 and b/android/app/src/main/res/raw/ident_302.mp4 differ diff --git a/android/app/src/main/res/raw/ident_303.mp4 b/android/app/src/main/res/raw/ident_303.mp4 index bad93c9f..2b536ad9 100644 Binary files a/android/app/src/main/res/raw/ident_303.mp4 and b/android/app/src/main/res/raw/ident_303.mp4 differ diff --git a/android/app/src/main/res/raw/ident_304.mp4 b/android/app/src/main/res/raw/ident_304.mp4 index 7575fee7..856a4685 100644 Binary files a/android/app/src/main/res/raw/ident_304.mp4 and b/android/app/src/main/res/raw/ident_304.mp4 differ diff --git a/android/app/src/main/res/raw/ident_305.mp4 b/android/app/src/main/res/raw/ident_305.mp4 index 79884e2c..3ac5f012 100644 Binary files a/android/app/src/main/res/raw/ident_305.mp4 and b/android/app/src/main/res/raw/ident_305.mp4 differ diff --git a/android/app/src/main/res/raw/ident_307.mp4 b/android/app/src/main/res/raw/ident_307.mp4 index 2b3278b2..7eae84c8 100644 Binary files a/android/app/src/main/res/raw/ident_307.mp4 and b/android/app/src/main/res/raw/ident_307.mp4 differ diff --git a/android/app/src/main/res/raw/ident_308.mp4 b/android/app/src/main/res/raw/ident_308.mp4 index 46e31e00..365de18d 100644 Binary files a/android/app/src/main/res/raw/ident_308.mp4 and b/android/app/src/main/res/raw/ident_308.mp4 differ diff --git a/android/app/src/main/res/raw/ident_309.mp4 b/android/app/src/main/res/raw/ident_309.mp4 index c6d6c50d..e8f51498 100644 Binary files a/android/app/src/main/res/raw/ident_309.mp4 and b/android/app/src/main/res/raw/ident_309.mp4 differ diff --git a/android/app/src/main/res/raw/ident_310.mp4 b/android/app/src/main/res/raw/ident_310.mp4 index 5d47f7dc..579d3bd8 100644 Binary files a/android/app/src/main/res/raw/ident_310.mp4 and b/android/app/src/main/res/raw/ident_310.mp4 differ diff --git a/android/app/src/main/res/raw/ident_401.mp4 b/android/app/src/main/res/raw/ident_401.mp4 index 98808d30..6c7cea94 100644 Binary files a/android/app/src/main/res/raw/ident_401.mp4 and b/android/app/src/main/res/raw/ident_401.mp4 differ diff --git a/android/app/src/main/res/raw/ident_601.mp4 b/android/app/src/main/res/raw/ident_601.mp4 index d3fb9b59..55536a97 100644 Binary files a/android/app/src/main/res/raw/ident_601.mp4 and b/android/app/src/main/res/raw/ident_601.mp4 differ diff --git a/android/app/src/main/res/raw/ident_602.mp4 b/android/app/src/main/res/raw/ident_602.mp4 index 0b002c1f..c5370fff 100644 Binary files a/android/app/src/main/res/raw/ident_602.mp4 and b/android/app/src/main/res/raw/ident_602.mp4 differ diff --git a/android/app/src/main/res/raw/ident_603.mp4 b/android/app/src/main/res/raw/ident_603.mp4 index 177fecd9..f7ee514f 100644 Binary files a/android/app/src/main/res/raw/ident_603.mp4 and b/android/app/src/main/res/raw/ident_603.mp4 differ diff --git a/android/app/src/main/res/raw/ident_611.mp4 b/android/app/src/main/res/raw/ident_611.mp4 index 508ae65a..9106443d 100644 Binary files a/android/app/src/main/res/raw/ident_611.mp4 and b/android/app/src/main/res/raw/ident_611.mp4 differ diff --git a/android/app/src/main/res/raw/ident_612.mp4 b/android/app/src/main/res/raw/ident_612.mp4 index e2c24414..63b0cb77 100644 Binary files a/android/app/src/main/res/raw/ident_612.mp4 and b/android/app/src/main/res/raw/ident_612.mp4 differ diff --git a/android/app/src/main/res/raw/ident_613.mp4 b/android/app/src/main/res/raw/ident_613.mp4 index 08e08d96..06eb7292 100644 Binary files a/android/app/src/main/res/raw/ident_613.mp4 and b/android/app/src/main/res/raw/ident_613.mp4 differ diff --git a/android/app/src/test/java/tv/orbit/classic/CornerLogoTest.kt b/android/app/src/test/java/tv/orbit/classic/CornerLogoTest.kt index ad5f4d71..d4bd277e 100644 --- a/android/app/src/test/java/tv/orbit/classic/CornerLogoTest.kt +++ b/android/app/src/test/java/tv/orbit/classic/CornerLogoTest.kt @@ -11,3 +11,18 @@ class CornerLogoTest { assertEquals(cornerLogoOffset(0), cornerLogoOffset(599_999)) } } + +/** Paul, 17 November 2026: the corner logo plays its animation about once an hour. */ +class CornerAnimationTest { + private val hour = 3_600_000L + @Test fun itPlaysOnceInTheFirstTwoMinutesOfEachHour() { + val t = 500 * hour + org.junit.Assert.assertTrue(cornerAnimationDue(t + 30_000, -1)) + org.junit.Assert.assertFalse(cornerAnimationDue(t + 30_000, 500)) + org.junit.Assert.assertFalse(cornerAnimationDue(t + 5 * 60_000, -1)) + org.junit.Assert.assertTrue(cornerAnimationDue(t + hour + 10_000, 500)) + } + @Test fun everyChannelHasOne() { + listOf(101, 105, 110, 206, 300, 305, 310, 401, 605, 614).forEach { org.junit.Assert.assertNotNull(cornerAnimation(it)) } + } +}