Commit graph

28 commits

Author SHA1 Message Date
KhooLy
0e3882eff8 Add seek acceleration to TV seekbar on held D-pad
Consecutive same-direction presses ramp up the jump amount: first 2 presses use
the profile seek interval, presses 3-7 triple it, and presses 8+ sextuple it.
Direction change or focus loss resets the counter. This lets quick taps do fine
scrubbing while holding the key covers large spans fast.
2026-07-03 12:45:24 +03:00
KhooLy
88d7e22ec2 Add skeleton loading rows to home screens on both platforms
While the home catalog is loading and no rows are available yet, both the mobile
and TV home screens now show 4 animated skeleton shelf placeholders instead of a
blank screen. The pulse animation matches the explore screen skeleton.
2026-07-03 12:41:07 +03:00
KhooLy
462de853ed Wire blurUnwatchedEpisodes setting to TV episode cards
EpisodeCard gains a blurUnwatched parameter that matches the alpha logic already
used in mobile MobileEpisodeRow: 0.5f for unwatched episodes when blur is on,
0.45f for watched episodes when blur is off. TvDetailScreenContent propagates
the profile setting so both platforms behave consistently.
2026-07-03 12:36:03 +03:00
KhooLy
08d719ab9c Apply FluxaDisplay to mobile settings heading and label texts
Section labels, row titles, display names, watch-time counters, and section
headers now use FluxaDisplay instead of the default system sans-serif, aligning
settings visual hierarchy with the rest of the app.
2026-07-03 12:34:50 +03:00
KhooLy
0080c63a6b Extend FOUC fix to TV detail screen
TvDetailScreenContent now accepts initialMeta and uses it as a hero background
fallback (background → poster → initialMeta?.background → initialMeta?.poster)
so the card's artwork is visible immediately while the full detail loads.
2026-07-03 12:30:30 +03:00
KhooLy
fd3f074069 Restore TV HomeScreen scroll position and shelf focus on back navigation
Save vertical scroll position and focused row index in HomeViewModel on dispose.
Restore them on re-entry: scroll to the saved position and focus the previously
active shelf's first card instead of always jumping to the hero play button.
Per-shelf FocusRequesters replace the single firstShelfFocusRequester so any
row can be individually targeted after navigation returns.
2026-07-03 12:29:41 +03:00
KhooLy
3fbf498dd2 Add image cache keys to uncached AsyncImage calls in 3 files
TvDetailScreenContent: detail background now uses ImageRequest with
memoryCacheKey("detail-bg:url"). OfflineDownloadPages: folder poster and
episode artwork wrapped in ImageRequest with downloads-group/episode keys.
TvLibraryEditors: URL preview field and folder row wrapped with keyed requests.
2026-07-03 12:24:55 +03:00
KhooLy
21cbc12506 Split mobile HomeScreen.kt (1078 lines) into focused composable files
Extract row composables into MobileHomeSections (MobileHomeHeroItem, HomeUserCollectionRow,
HomeCategoryRow), card composables into MobileHomeCards (HomeCatalogCard,
MobileCollectionFolderCard, layout helpers), and bottom sheet into
MobileHomeContinueWatching. HomeScreen.kt retains only the top-level composable,
MobileHomeRowSpec, and spec builder functions.
2026-07-03 12:20:22 +03:00
KhooLy
423609a0e3 Split TvSettingsSections.kt (818 lines) into focused section files
Dissolve the monolithic sections file into TvSettingsAccountSection,
TvSettingsAppearanceSection, TvSettingsContentSection, TvSettingsPlaybackSection,
and TvSettingsSystemSection. TvSettingsPreviews retains the preview composables.
All section functions stay internal for same-module access from TvSettingsScreen.
2026-07-03 12:20:12 +03:00
KhooLy
331b989ce8 Migrate color literals to FluxaColors tokens across 23 files
Replace hex color literals with named FluxaColors constants in library, error, TV
library/detail/hero, offline, settings tiles, addon store, welcome, profile, mobile
detail/settings/library/addons/auth screens.
2026-07-03 12:20:05 +03:00
KhooLy
44683af3c1 Migrate tween literals to AnimDuration tokens across 14 files
Replace all raw tween(N) integer literals with named FluxaDimensions.AnimDuration
constants in player overlays, sidebar, source panel, profile components, parents
guide, login, explore, detail, library, source, search, and route transitions.
2026-07-03 12:19:54 +03:00
KhooLy
c9ecb5477a Expand FluxaColors and FluxaDimensions design token sets
Add 10 semantic color tokens (backgroundAmoled, backgroundHeroNavy, backgroundNavy,
backgroundNearBlack, surfaceDark, errorRed, successGreen, infoBlue, subtitleRed,
subtitleBlue) and 20+ AnimDuration constants covering blink, quick, scaleAlpha,
fadeIn, contentExpand, cardFocusScale, settingsExpand, heroSnap, parentsContainer,
nextEpisode, progressRing, sidebarSlide, heroReveal, ambientColor, loginPulse, marquee.
2026-07-03 12:19:44 +03:00
KhooLy
75ef192177 Fix six libass bugs: multi-track mixing, duration inference, font dir, render perf, thread safety, and subtitle matching
Multi-track relay (high): relay now tracks selectedTrackId driven by
updateTracks(). LibassInterceptingTrackOutput drops samples for non-selected
tracks and re-primes the header (via headerGeneration counter) when the
selected track switches. NativeLibassSubtitleOverlay gates relayRenderer on
embeddedSubtitle != null so disabling subs actually stops drawing.

Duration inference (high): pendingBody is flushed in onSeekFlush() with
lastInterEventMs capped to 5s, fixing the last-subtitle-never-shown problem.
Duration cap lowered from 60s to 30s to reduce lingering on sparse dialogue.

Font fallback (medium): LibassInjectingExtractorsFactory now accepts fontsDir
and threads it through to setHeader(), matching what the local/external path
already did. C++ nativeCreate uses fonts_dir for ass_set_fonts_dir and probes
for a NotoSans-Regular.ttf default_font instead of passing nullptr.

Render loop (medium): C++ nativeRender returns jint (1=has image, 0=no image).
When detect_change==0 and bitmap dimensions are unchanged it skips memset+blend
entirely and returns the cached last_had_image. Kotlin onDraw uses the int
result to decide whether to draw and switches to postInvalidateDelayed(100)
during subtitle-free periods instead of postInvalidateOnAnimation at 60 fps.

Thread safety (low): ensure_api() replaced bool+flag with std::call_once so
the first-call race between ExoPlayer's loader thread and main is eliminated.

Subtitle matching (low): selectedNativeAssSubtitle now tries label then URL
then (label+language) before falling back to language-only, preventing two
external subs in the same language from selecting the wrong one.
fetchSubtitleBytes switches to OkHttp and forwards StreamRequestPolicy headers
so addon URLs that require Referer/auth don't 403.
2026-07-03 11:53:57 +03:00
KhooLy
adf7700f7d Fix mpv/ExoPlayer audio passthrough, channel layout, AO, and DV track selection
mpv:
- Set ao=audiotrack explicitly so the AudioTrack output is guaranteed
  (avoids openSLES which lacks encoded passthrough)
- Add audio-channels=7.1,5.1,stereo so mpv negotiates multichannel
  instead of defaulting to auto-safe stereo downmix
- Build audio-spdif at init time by querying AudioManager output device
  encodings; only advertises AC3/E-AC3/DTS/DTS-HD/TrueHD formats the
  device actually reports

ExoPlayer:
- Guard setVideoEffects(emptyList()) behind a videoEffectsActive flag:
  only call it when IptPqc2ToneMapEffect was actually installed, never
  on a clean path — the empty-list call triggers the GL VideoFrameProcessor
  pipeline in media3 1.10.1 which tone-maps HDR even for an empty effect list
- detectPreferredVideoMimeType now accepts Context and checks display +
  decoder DV capability first; on fully DV-capable devices it returns
  VIDEO_DOLBY_VISION so DV variant tracks are preferred rather than
  deprioritized behind H.265/H.264
2026-07-03 03:51:49 +03:00
KhooLy
54819aad7b Neutralize FluxaColors surface tokens and point settings back at them 2026-07-02 01:20:40 +03:00
KhooLy
8f1500ff4c Restore neutral gray settings palette over blue-tinted surface tokens 2026-07-02 01:19:19 +03:00
KhooLy
348c4ad4bb Clean up mobile settings visuals and align them with design tokens 2026-07-02 01:15:47 +03:00
KhooLy
876e7bcecb Prefetch nested shelf posters and size-qualify TV image cache keys
Home vertical lists on both platforms now compose the first four cards of
upcoming rows ahead of scroll via LazyListPrefetchStrategy. TV card
requests move to the size-qualified memory cache key helper mobile already
used, so the same URL requested at poster and expanded sizes no longer
collides under one key; the shelf neighbor prewarm and expanded-poster
prefetch write the matching keys.
2026-07-02 01:01:55 +03:00
KhooLy
c9fdda4274 Unify mobile and TV player chrome through shared tokens
Scrim heights and alphas, seekbar track height, and the buffer/track
colors now come from FluxaDimensions.PlayerChrome and FluxaColors, so both
players render the same chrome: 160dp/0.72 top scrim, 230dp/0.86 bottom
scrim, 4dp track (TV was 3dp).
2026-07-02 00:52:14 +03:00
KhooLy
f4f233f59d Stagger TV hero content reveal and consolidate motion durations
Billboard rotations now play one orchestrated moment: logo, metadata,
description, and buttons fade and rise in sequence, driven by a single
Animatable read inside graphicsLayer so the stagger never recomposes the
panel. Ad-hoc tween literals across hero, shelves, cards, and the ambient
tint move to FluxaDimensions.AnimDuration tokens; the hero title fallback
also picks up the display face.
2026-07-02 00:51:01 +03:00
KhooLy
327e869488 Fade TV shelf rows out under the rail gutter
Rows now dissolve at the left edge instead of hard-clipping. The DstIn
fade needs offscreen compositing, so it only engages once the row has
scrolled; rows sitting at their start render with no extra cost.
2026-07-02 00:49:44 +03:00
KhooLy
f2bb2d902e Tint hero scrims with a color sampled from the backdrop
rememberAmbientHeroColor reuses the existing Palette extraction (LRU
cached) to pull the dark muted tone of the current hero artwork, blended
toward the app background and animated between billboard rotations. TV
bleeds the tint under the shelf area behind the LazyColumn; mobile gets a
glow band above the hero fold.
2026-07-02 00:48:17 +03:00
KhooLy
a2e85be74c Release expanded-poster trailer player when playback stops
Each once-focused card kept its ExoPlayer instance alive until the card
left composition, so scrolling a shelf accumulated idle decoders. Release
on stop caps live trailer players at one.
2026-07-02 00:46:36 +03:00
KhooLy
a32c01faba Upgrade TV card focus treatment to scale, accent ring, and glow
Replace the static 3.5dp focus border and duplicate overlay ring with the
tv-material Surface focus system: 1.05 focused scale (disabled when the
profile turns animations off), a 2.5dp accent border, and a soft black
glow. Shelf rows stop passing no-op positioning callbacks so cards without
expanded posters detach their layout listeners.
2026-07-02 00:46:01 +03:00
KhooLy
d31ed1017e Make cards skippable and stop focus-driven card rebuilds
Add a Compose stability configuration declaring Meta and UserProfile
stable (both are immutable data classes in the data module) so card
composables skip recomposition when shelf state changes. In TvMovieCard,
gate onGloballyPositioned behind expanded/focus consumers, keep the
modifier chain constant by drawing the focus border in transparent when
unfocused, stop keying the artwork request on focus state so D-pad moves
no longer rebuild ImageRequests unless a focus GIF exists, and drop
crossfade allocations. Continue-watching card scale now animates in a
graphicsLayer block instead of recomposing.
2026-07-02 00:44:22 +03:00
KhooLy
0e6835be31 Add Archivo variable display face and card type hierarchy
Bundle Archivo (OFL) as the brand display family with width/weight axes;
displays, titles, shelf row titles, and Top Ten numerals now render in
expanded Archivo. Card titles drop from Black/Bold to SemiBold with Medium
metadata so shelves get visible hierarchy.
2026-07-02 00:38:49 +03:00
KhooLy
663c1154f1 Consolidate UI palette into FluxaColors tokens
Replace scattered color literals (Netflix-red E50914/E53935 progress and
accent fallbacks, drifting dark surface tones) with a single FluxaColors
object; AppTheme and ThemeHelper now source from the same tokens. Accent
fallback unifies on the theme ember E85D3F.
2026-07-02 00:34:30 +03:00
KhooLy
9384e1257b Initial commit 2026-06-05 14:43:08 +03:00