Skip to content

Anime support#31

Merged
sohilsayed merged 13 commits into
mainfrom
anime
Jun 23, 2026
Merged

Anime support#31
sohilsayed merged 13 commits into
mainfrom
anime

Conversation

@sohilsayed

Copy link
Copy Markdown
Owner

Sirush and others added 13 commits June 23, 2026 06:48
- Copied all player files from Anikku (PlayerActivity, MPV, Controls, Cast, Settings)
- Added missing infrastructure (CustomButton interactors, DownloadPreferences methods, Episode db model, getEpisodeSort, AnimeCoverFetcher, SetAnimeViewerFlags)
- Adapted PlayerViewModel and ExternalIntents to use AnimeHistoryUpdate and tachiyomi episode domain models
- Wired new player settings screens to Voyager navigation
- Added MIXED_ED skip type to AniSkipApi
- Remove broken anime discord rpc
* feat: port anime UI and mining features

* fix: stabilize anime standalone playback

Queue standalone local video loads until the MPV surface is attached, route Android video intents into the player, keep subtitle state clear when subtitles are disabled, and search both Jimaku anime and live-action entries.
Domain:
- Add initialized field propagation and titleOrUrl() to anime model
- Update episode filter model

Local anime source:
- Implement video file discovery with recursive subdirectory support
- Add details.json metadata parsing for title, author, description, genre, status
- Support cover and background image lookup
- Add ArchiveAnime with video format support (avi, flv, mkv, mov, mp4, webm, wmv)
- Fix fetch type detection using ArchiveAnime.isSupported()

Download manager:
- Add buildVideoForPlayer() with metadata.json subtitle track remapping
- Fix isEpisodeDownloaded() signature (remove skipCache param)
- Merge anime download path: animedownloads/ -> downloads/ (matches anikku)

Player controls:
- Rewrite gesture handler: manual double-tap with subtitle tap interception
- Fix speed button: click cycles speed (0.25 steps), long-click opens sheet
- Fix HUD overlay animation: use enter spec (100ms) for fade-in
- Fix OCR popup outside-tap dismiss: sibling layout instead of parent wrapper
- Wire onPlaybackSpeedChange through to MPVLib
- Make ControlsButton use clickable/combinedClickable conditionally
- Subtitle lookup popup: wrap in dismiss-on-backdrop-tap Box

Browse UI:
- Use titleOrUrl() fallback for extensions with blank titles
- Use GridCells.Adaptive(128.dp) for responsive grid
- Pass filters on popular/latest load
- Respect sAnime.initialized instead of hardcoding true
- Always show local anime source regardless of language filter

Cleanup:
- Remove Anime.isLocal() leak from manga LocalSource.kt
- Update all anime imports to use entries.anime package
- Fix EpisodeLoader to use AnimeDownloadManager and LocalAnimeSource
- AnimeDownloader.start() made non-suspend (matches anikku)
- AnimeDownloadProvider.getAnimeDir() now returns UniFile (throws)
- AnimeDownloadPendingDeleter updated to anikku's API (addEpisodes, getPendingEpisodes)
- AnimeDownloadCache: added removeSource, getTotalDownloadCount/Size, getDownloadSize
- DownloadPreferences: added downloadFillermarkedItems, removeExcludeAnimeCategories
- Added AnimeDownload.fromEpisodeId companion
- AnimeDownloader: added updateQueue, updated queueEpisodes signature
- Fixed all callers (EpisodeLoader, AnimeScreenModel, DownloadManager, etc.)
- Add AnimeSearchScreenModel abstract base with search/filter/state
- Rewrite GlobalAnimeSearchScreenModel to extend base
- Rewrite GlobalAnimeSearchScreen Voyager screen with single-source jump
- Create presentation-layer composables: screens, toolbar, card row, result items
- Add disabledAnimeSources/pinnedAnimeSources to SourcePreferences
- Adapt to use AnimeComfortableGridItem (not EntryComfortableGridItem)
- Delete 17 anime .sq files from sqldelight/ (manga DB) — now matches main
- Switch all anime repos from DatabaseHandler to AnimeDatabaseHandler:
  EpisodeRepositoryImpl, AnimeCategoryRepositoryImpl, AnimeHistoryRepositoryImpl,
  AnimeMergeRepositoryImpl, AnimeSourceRepositoryImpl, StubAnimeSourceRepositoryImpl,
  AnimeExtensionRepoRepositoryImpl, CustomButtonRepositoryImpl
- Fix AppModule.kt DB names: manga='tachiyomi.db', anime='tachiyomi.animedb'
- Update sqldelightanime/ schemas: animes.sq (UpdateStrategy), animehistory.sq
  (watch_duration), animehistoryView.sq, merged_anime.sq, episodes.sq, animelibView.sq
- Add missing fields to AnimeUpdate and MergeAnimeSettingsUpdate domain models
- Add SeasonAnime and SeasonDisplayMode domain models
Move:
  ui/anime/*        -> ui/entries/anime/
  presentation/anime/* -> presentation/entries/anime/
  presentation/anime/components/* -> presentation/entries/anime/components/
  presentation/anime/library/* -> presentation/entries/anime/library/
  ui/anime/library/* -> ui/entries/anime/library/
  ui/anime/track/*   -> ui/entries/anime/track/
  AnimeScreenConstants.kt -> presentation/entries/ (package: entries, not entries.anime)

Path-only refactor - no implementation changes, only package declarations
and imports updated. Directory layout now matches anikku for clean diffs.
…n system

- Rewrote AnimeScreen.kt to use FastScrollLazyVerticalGrid with FetchType switching
- Created ItemHeader.kt, MissingItemCountListItem.kt, SeasonSettingsDialog.kt from anikku
- Deleted EpisodeHeader.kt, MissingEpisodeCountListItem.kt
- Added season system: flags repository, interactor (SetAnimeSeasonFlags), NoSeasonsException, model extensions
- Added anime_num_seasons plural
- Rewrote BrowseTab with Manga/Anime segmented control replacing flat sub-tabs
- Manga mode: Sources, Feed (optional), Extensions, Migrate
- Anime mode: Anime Sources, Anime Extensions
- Added global search action per mode (GlobalSearchScreen / GlobalAnimeSearchScreen)
- Built and verified zero compilation errors
…Anime anikku parity

- BrowseTab: Manga/Anime segmented control, remove duplicate global search from toolbar,
  smooth mode switching via LaunchedEffect instead of key() wrapper
- AnimeSourcesTab: Add global search (TravelExplore) and filter (FilterList) actions
- AnimeSourcesFilterScreen: Create filter screen (screen + model + presentation) for
  anime sources, matching anikku pattern
- Fix default listing to Popular (was incorrectly defaulting to Search with source.name)
- NetworkToLocalAnime: Rewrite to match anikku (AnimeSourceManager param, in-memory
  title copy pattern), remove insertNetworkAnime SQL approach
- AnimeRepository: Rename insert → insertAnime, remove insertNetworkAnime to match anikku
- Register SetAnimeSeasonFlags in AnimeDomainModule (fixes crash on season settings)
- Remove stale getIdByUrlAndSource SQL query from animes.sq
@sohilsayed sohilsayed merged commit 36b3c31 into main Jun 23, 2026
1 check failed
@github-actions github-actions Bot deleted the anime branch June 23, 2026 03:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants