Compare commits

..
534 Commits
Author SHA1 Message Date
github-actions[bot] 849ef6efe5 chore: bump version to 1.27.0 2026-03-14 00:53:01 +00:00
edde746 e968a20f4c fix(livetv): soften EPG grid program styling 2026-03-13 18:49:40 +01:00
edde746 7a6b866c28 fix(livetv): fetch boundary-spanning programs
close #686
2026-03-13 18:45:00 +01:00
edde746 6ccbaed3fd fix(livetv): always bold EPG program titles in guide grid
close #687
2026-03-13 18:20:47 +01:00
edde746 d01628a262 fix(android): use OkHttp connection pooling to prevent high-bitrate stutter
Replace DefaultHttpDataSource with OkHttpDataSource for TCP connection
reuse on buffer refill. Increase buffer sizes for devices with >=1GB RAM.
2026-03-13 17:23:06 +01:00
edde746 675ac84486 fix: use settings-style bottom sheet for browse grouping picker 2026-03-13 12:05:51 +01:00
edde746 e84dc93910 fix: prevent tab revert and overflow bleed on mobile tab switch
Skip auto-focus in touch mode to prevent ensureVisible() from fighting
TabBarView animations, and clip each tab with ClipRect to stop hub row
overflow bleeding into adjacent tabs during swipe transitions.
2026-03-13 00:09:24 +01:00
edde746 3d30ea1342 fix(macos): reduce idle CPU when video player is paused
- Remove vulkan-swap-mode mailbox (continuous GPU rendering even when paused)
- End playback activity assertion on pause, restore on play
- Fix PerformanceStatsService persistent frame callback leak
2026-03-12 23:22:58 +01:00
edde746 efd28d3ca3 docs: add AUR package to readme 2026-03-12 13:20:16 +01:00
edde746 8a28a2c398 fix: only autofocus bottom sheets in keyboard/dpad mode 2026-03-12 05:02:52 +01:00
edde746 c6fa6afa9b fix: android thread safety
- ExoPlayerPlugin: move all MPV JNI calls off main thread via runOnExecutor
- WatchNextPlugin: run ContentProvider ops on IO executor with error handling
- MpvPlayerCore: guard executor methods against dispose race (RejectedExecutionException)
- MainActivity: fix PiP null engine NPE with safe flutterEngine?.let
2026-03-12 03:34:32 +01:00
edde746 912ebc2f90 fix: cooldown resume health probes, debounce connectivity, coalesce concurrent checks
Add per-platform cooldown on resume health probes (10s mobile, 2min
desktop). Debounce connectivity listener by 2s. Coalesce concurrent
checkServerHealth and reconnectOfflineServers into single in-flight
futures.
2026-03-12 02:52:14 +01:00
edde746 f04b49e260 fix: guard mpv event handler during disposal 2026-03-12 02:44:50 +01:00
edde746 a17458ff9b fix: handle DBusServiceUnknownException on Linux without NetworkManager 2026-03-12 02:24:00 +01:00
edde746 c062dd944e feat: inline season tabs and d-pad focus improvements 2026-03-12 00:57:51 +01:00
edde746 1a4516bdd1 Merge branch 'feature/respect-season-mode' 2026-03-11 23:09:23 +01:00
edde746 5538e0627b refactor: remove SeasonDetailScreen, unify into MediaDetailScreen
Extract EpisodeCard to its own widget file. MediaDetailScreen now handles
isSeason by showing episodes directly, with proper watch state tracking,
deletion handling, and D-pad focus navigation. Hide empty overview sections.
2026-03-11 23:08:39 +01:00
edde746 7febfa9771 fix: deduplicate episode fetching and use lazy list for flattened seasons 2026-03-11 22:35:30 +01:00
Micah Morrison 160be52f02 Fix parsing setting value 2026-03-11 17:13:11 -04:00
edde746 828d57af24 fix: auto-reconnect stream after network loss during playback 2026-03-11 22:08:11 +01:00
edde746 1f7fb2201c fix: handle null ratingKey in folder browsing 2026-03-11 22:08:11 +01:00
Micah Morrison 32ae51142f Respect the Plex server library season view mode 2026-03-11 16:42:49 -04:00
edde746andGitHub 7014df7a0e Merge pull request #680 from micahmo/fix/always-on-top
Fix issue with always on top getting stuck
2026-03-11 20:50:49 +01:00
Micah Morrison cb0ed15c0c Fix issue with always on top getting stuck 2026-03-11 15:00:17 -04:00
edde746 d4e9364d29 fix: handle TogglePlayPauseEvent for macOS media key
close #679
2026-03-11 18:28:07 +01:00
edde746 4681d60850 fix: hide admin actions from non-admin users
close #677
2026-03-11 18:18:27 +01:00
edde746 78052dc07f fix: player stuck on skip credits with no next episode
close #678
2026-03-11 18:02:33 +01:00
edde746 67c66ff0c1 fix: prevent layout shift for image placeholders 2026-03-11 15:02:38 +01:00
edde746 d1bb99635a feat: configurable intro/credits marker regex patterns
Add settings to customize regex patterns for matching intro and credits
markers in chapter titles, with the current hardcoded values as defaults.
Also reclassifies real markers with non-standard type strings against the
configured patterns.
2026-03-11 15:00:24 +01:00
github-actions[bot] 69092e3656 chore: update cask to 1.26.1 2026-03-11 13:32:42 +00:00
github-actions[bot] 98138a4f35 chore: bump version to 1.26.1 2026-03-11 13:09:47 +00:00
edde746 25c7f325b6 feat: use git commit SHA for sentry release version 2026-03-11 14:09:14 +01:00
edde746 5dbaf961b7 fix: ASS subtitles broken when DV mode enabled
close #674
2026-03-11 14:04:21 +01:00
edde746 b4471fab49 fix: add D3D11 fallback for gpu-api on Windows 2026-03-11 13:54:21 +01:00
edde746 307fd354d6 fix: make overlay sheets dismissible when no descendant is focused
close #673
2026-03-11 13:30:07 +01:00
edde746 a3b5557185 fix: use stream-lavf-o instead of stream-lavf-o-append for reconnect
stream-lavf-o-append is an mpv "action" that only works as an
init option, not a runtime property — all calls returned -3.
Using stream-lavf-o as a single property set works correctly.
2026-03-11 09:40:39 +01:00
edde746 3c491be690 fix: handle mpv end-file errors with global snackbar 2026-03-11 09:29:16 +01:00
edde746 580c1d82e5 fix: stuck network check on Linux without NetworkManager
close #670
2026-03-11 08:55:25 +01:00
github-actions[bot] 4cc83006ec chore: update cask to 1.26.0 2026-03-11 04:33:26 +00:00
edde746 4954c9c569 fix: replace tunneling reopen with simple parameter toggle
Removes the full player restart cycle for tunneling changes that was
causing infinite spinning/blank screen on Amlogic devices (Onn 4K Pro).
2026-03-11 05:08:43 +01:00
edde746 8f1b40d143 fix: handle string childCount in collections 2026-03-11 05:08:43 +01:00
github-actions[bot] d72153c25a chore: bump version to 1.26.0 2026-03-11 04:08:09 +00:00
edde746 666b59c293 refactor(native-player): share player helpers 2026-03-11 01:30:11 +01:00
edde746 7543a8c55b refactor: clean up windows code 2026-03-10 22:24:14 +01:00
edde746 bfc7be2b80 fix: default to Vulkan on Windows
close #653
2026-03-10 19:42:43 +01:00
edde746 8b2c68f3ae chore: switch Windows libmpv builds to SourceForge 2026-03-10 19:08:04 +01:00
edde746 9aa019fe6f fix: ANR in detachSurface 2026-03-10 19:07:33 +01:00
edde746 23a100afdc feat: auto-reconnect VOD playback after network loss 2026-03-10 18:47:31 +01:00
edde746 af2ac2c993 fix: suppress ASS GL thread crash, update ass-media to 0.4.0 2026-03-10 06:41:43 +01:00
edde746 166e73cdaa fix: sync button focus nodes with actual action count 2026-03-10 06:08:55 +01:00
edde746 73fe9e054f fix: guard unsafe .first/.last calls to prevent StateError 2026-03-10 03:50:12 +01:00
edde746 42e066288f fix: clickable title event bubbling and movie support 2026-03-10 01:57:28 +01:00
edde746 682a04f047 feat: show per-server connection status on splash screen 2026-03-10 01:50:19 +01:00
edde746 29cb88e6e2 fix: translate remaining strings 2026-03-10 01:21:03 +01:00
edde746 6daf77c890 feat: convert settings dialogs to platform-adaptive menus
Replace AlertDialog-based selection dialogs with popup dropdowns on
desktop/TV and bottom sheets on mobile, matching the context menu
pattern. Fix popup background blending into cards by tinting surface.
2026-03-10 01:18:33 +01:00
edde746 0372840ee1 fix: localize EPG day names and reduce channel column width
close #661
2026-03-10 00:19:16 +01:00
edde746 3c51760203 feat: mouse-only clickable text on media cards 2026-03-09 23:56:24 +01:00
edde746 f3c735e3a1 fix: remove Docker bridge IP filter 2026-03-09 17:35:28 +01:00
edde746 7784cb7511 fix: TMDB icon gradient 2026-03-09 16:24:59 +01:00
edde746 82b0de9223 feat: display movie edition titles across all views 2026-03-09 16:16:37 +01:00
edde746 a6852d716f fix: handle null fields in PlexHome deserialization 2026-03-09 15:42:33 +01:00
edde746 92dfe5b41f fix: lazy Sparkle init to prevent macOS startup hang 2026-03-09 14:39:16 +01:00
edde746 16e96cdde0 fix: handle null fields in folder metadata deserialization 2026-03-09 14:10:37 +01:00
edde746 61e4bda616 fix: content strip text colors in light mode
close #659
2026-03-09 12:53:16 +01:00
edde746 e69fab87d0 fix: handle DVR tune error responses and show to user 2026-03-09 11:33:54 +01:00
edde746 a3e738773b fix: handle Metadata as list in DVR tune response 2026-03-09 10:52:57 +01:00
github-actions[bot] 425957c804 chore: update cask to 1.25.1 2026-03-09 06:39:08 +00:00
github-actions[bot] efa1cc8bd8 chore: bump version to 1.25.1 2026-03-09 06:22:29 +00:00
edde746 0fc64cdf81 fix: catch seek PlatformException at source, remove coordinator
Catch COMMAND_FAILED/NOT_INITIALIZED in PlayerNative.seek() and
PlayerAndroid.seek() directly, preventing unhandled PlatformException
crashes on macOS app resume. Remove the ~200-line
_PendingSeekCoordinator system and revert all callsites to direct
player.seek(clampSeekPosition(...)). Keep seekable property/stream
and media controls gating. Add ExoPlayer seekable emission.
2026-03-09 07:21:36 +01:00
edde746 d08c4c905f fix: gamepad select registering as long press 2026-03-09 07:14:41 +01:00
edde746 43b9bd7038 fix: bump universal_gamepad to 1.5.4 2026-03-09 07:06:22 +01:00
edde746 2dddd00fd3 fix: d-pad navigation on Android 2026-03-09 06:01:15 +01:00
edde746 5be7b43cb8 fix: improve content strip text visibility
close #656
2026-03-09 01:04:14 +01:00
edde746 965d9540fa fix: double sparkle update check 2026-03-09 00:29:58 +01:00
edde746 65bb7bd44e fix: catch wakelock exceptions on Linux 2026-03-08 21:20:51 +01:00
edde746 a5ade78cd6 fix: remove unused variable warning 2026-03-08 19:40:11 +01:00
edde746 57420e51cf fix: lazy client fetch in context menu 2026-03-08 19:03:03 +01:00
edde746 bec8b593be fix: bump auto_updater 2026-03-08 18:50:19 +01:00
edde746 c62e406749 refactor: gate sentry behind build flag 2026-03-08 18:15:19 +01:00
github-actions[bot] d503f6c6ce chore: update cask to 1.25.0 2026-03-08 16:48:29 +00:00
github-actions[bot] ff6e3ee92a chore: bump version to 1.25.0 2026-03-08 16:24:11 +00:00
edde746 16676bca49 perf: watch together CPU overhead 2026-03-08 16:57:15 +01:00
edde746 9e2e1f72ce refactor: remove debug token i18n strings 2026-03-08 15:13:19 +01:00
edde746 f85afbe576 fix: gamepad ANR on Android 2026-03-08 14:15:32 +01:00
edde746 6fa6b34b59 fix: player stuck after show ends with no next episode
close #650
2026-03-08 13:51:25 +01:00
edde746 7a1f677c75 fix: content strip lint warnings 2026-03-07 22:10:45 +01:00
edde746 de28691481 fix: track selection persistence with stale cache 2026-03-07 22:07:29 +01:00
edde746 686a61ac74 fix: hero section bottom fade only applies to image 2026-03-07 20:52:28 +01:00
edde746 0b1f64ef8a refactor: simplify mobile player controls
close #641
2026-03-07 20:48:17 +01:00
edde746 5b910fd3d7 fix: mpv config TextField dpad/back key navigation
Add PopScope to handle Android TV platform-level back, add down arrow
exit on last line, and fix back key trap when save preset is disabled.
2026-03-07 20:32:02 +01:00
edde746 c56e73eefe feat: add content strip for dpad navigation 2026-03-07 20:17:28 +01:00
edde746 7cfa18e1e9 fix: remove redundant thumbnail popup during dpad timeline seeking 2026-03-07 18:29:52 +01:00
edde746 06034bb8e7 feat: scale queue items for tablet screens
close #644
2026-03-07 17:06:13 +01:00
edde746 7b20543fa1 fix: support non-1x playback speed in audio position bypass
Scale raw AudioTrack position by playback speed to convert from real
time to media time. Captures reference points on speed changes for
correct mid-playback transitions.
2026-03-07 16:40:48 +01:00
edde746 d207185130 fix: bypass DefaultAudioSink position clamp for large audio frames
Fixes video stutter on files with 120ms Opus audio frames (e.g. Amlogic
S905X4). DefaultAudioSink clamps getCurrentPositionUs to writtenDuration
which lags between bursts, creating a sawtooth pattern that drops video
frames. PositionFixAudioSink bypasses the clamp using the raw AudioTrack
position when the delegate falls behind.
2026-03-07 16:27:29 +01:00
edde746 66628e1bca feat: add pt, ja, ru, pl, da, nb translations 2026-03-06 22:34:45 +01:00
edde746 beff4f9ca0 feat: add watch together playback rejoin flow
close #639
2026-03-06 20:42:18 +01:00
edde746 1318c54c0c feat: improve performance overlay layout and add decoder details 2026-03-06 19:25:41 +01:00
edde746 b05d69b10f fix: filter hub detail view by library section
close #638
2026-03-06 18:36:45 +01:00
edde746 7825490b0f fix: filter Windows file-lock cache manager errors from Sentry 2026-03-06 18:30:47 +01:00
edde746 c06b0efedc fix: correct linux package license metadata 2026-03-06 15:07:48 +01:00
edde746 43f4736936 fix: reopen ExoPlayer when tunneling mode changes 2026-03-06 13:49:03 +01:00
edde746 cf8f1849aa fix: harden watch together teardown sync 2026-03-06 12:52:28 +01:00
edde746 c9a1bc97c4 fix: remove dead state paths and restore track hotkeys 2026-03-06 11:50:45 +01:00
edde746 581f665f58 fix: restore iOS inline player after PiP closes 2026-03-06 11:35:25 +01:00
edde746 7b3a8ad642 fix: guard missing client in season detail screen 2026-03-06 11:09:42 +01:00
edde746 c1e2bc36ea refactor: share Apple MPV core and media helpers 2026-03-06 10:16:33 +01:00
edde746 72aed76a1c fix: remove unused _applyFilterWithFallback 2026-03-06 07:55:59 +01:00
edde746 7ae293631a fix: trust server-computed subtitle selection flags
The Plex server already applies all preference levels (account,
show/season, per-item) into stream `selected` flags. Remove redundant
client-side subtitleMode/account prefs logic and show/season metadata
fetching (2 fewer API calls per episode).
2026-03-06 04:25:47 +01:00
edde746 f3d24866b7 fix: trust Plex stream selection for subtitle defaults 2026-03-06 03:43:10 +01:00
edde746 985ba5d2c7 fix: toggle PiP button closes PiP when already active 2026-03-06 03:08:28 +01:00
edde746andGitHub f7ca80de77 Merge pull request #637 from micahmo/fix/setting-episode-artwork
Fix an issue setting episode artwork
2026-03-06 03:08:20 +01:00
Micah Morrison a9c7130d55 Fix an issue setting episode artwork 2026-03-05 19:21:30 -05:00
edde746 9730ffd541 fix: coerce subtitleMode string from Plex API to num 2026-03-05 21:53:52 +01:00
edde746 232f018ae7 fix: report JSON deserialization errors 2026-03-05 21:00:52 +01:00
edde746 8571ee74c4 fix: use addedAt for unwatched on-deck sort fallback
close #636
2026-03-05 19:57:36 +01:00
edde746 9566e0b897 perf: parallelize show/season metadata fetches 2026-03-05 18:56:52 +01:00
edde746 863f90f65d fix: respect series-level subtitle mode for episodes 2026-03-05 18:55:44 +01:00
edde746 22a733280a fix: respect view mode in detail screens, disable scale in list mode
close #631
2026-03-05 17:38:38 +01:00
edde746 a4008d3d6b fix: move mpv operations off UI thread 2026-03-05 16:55:44 +01:00
edde746 819d7b0f8f fix: scope library display settings per user profile
close #630
2026-03-05 16:42:13 +01:00
edde746 c785ce1f88 fix: queue sheet image loading priority with itemExtent 2026-03-05 16:11:14 +01:00
edde746 0c3588210a fix: pause hero auto-scroll on desktop background transition 2026-03-05 15:36:35 +01:00
edde746 db57fa73ce feat: add option to hide bottom navigation bar labels 2026-03-05 15:05:48 +01:00
edde746 0269825179 fix: windows single instance mutex 2026-03-05 14:59:40 +01:00
edde746 588b413223 fix: browse tab scrolling after alpha jump libraries 2026-03-05 14:41:21 +01:00
edde746 a2cd3397c9 fix: desktop context menu position and bottom sheet sizing 2026-03-05 14:25:23 +01:00
edde746 268f293704 refactor: deduplicate Dolby Vision conversion code
- Extract shared processNal() for NAL classification/conversion logic
- Share DoviExtractorOutputWrapper between MKV and MP4 paths
- Deduplicate DV profile codec queries via deviceSupportsDvProfile()
- Collapse repeated doviTrackOutput access chain in stats
2026-03-05 12:02:33 +01:00
edde746 317d5dbdd9 feat: DV Profile 7→8.1 RPU conversion via libdovi
Convert Dolby Vision Profile 7 RPU NALUs to Profile 8.1 using libdovi
native bridge, preserving dynamic tone mapping on devices with DV8
decoders. Falls back to HEVC stripping when no DV8 decoder is present.

- Add JNI bridge (dovi_bridge.cpp) wrapping libdovi's RPU converter
- Download prebuilt libdovi from edde746/libdovi-builds releases
- DoviConvertingTrackOutput: DV81 mode converts RPUs, HEVC_STRIP strips
- Retry logic: if native DV7 decoding fails, auto-retry with conversion
- Performance overlay shows active DV conversion mode
2026-03-05 11:11:57 +01:00
edde746 7f2d548d32 fix: item 0 steals focus after sidenav return 2026-03-04 18:39:49 +01:00
edde746 5877673755 fix: reduce UI padding between media items
close #629
2026-03-04 18:36:12 +01:00
edde746 3b351d7634 fix: iOS OOM during PiP playback cycles
Cancel leaked stream subscriptions in video player dispose and flush
sample buffer layer on PiP teardown/cleanup to release video frames.
2026-03-04 17:34:30 +01:00
edde746 e6ee83d9c2 fix: preserve home screen scroll position on back navigation 2026-03-04 16:34:36 +01:00
edde746 8b57e810ab feat: detail screen context menu button 2026-03-04 15:11:46 +01:00
edde746 4121d568c8 fix: sanitize mpv event channel strings for valid UTF-8 2026-03-04 14:59:11 +01:00
edde746 551bd83ffe fix: player disposed race condition 2026-03-04 14:37:51 +01:00
edde746 5f4e4bfdd3 fix: ExoPlayer fallback for unsupported DV formats
- Detect decoder hangs via AnalyticsListener (onVideoDecoderInitialized
  → onRenderedFirstFrame gap, confirmed by DecoderCounters)
- Detect deselected video tracks and trigger immediate MPV fallback
- Use reinhard tone-mapping on GPUs without compute shaders
2026-03-04 13:18:40 +01:00
edde746 8cd48f3af5 fix: firstClient null check race 2026-03-04 10:01:40 +01:00
edde746 13b5d7bae8 feat: secondary subtitle tracks
close #625
2026-03-04 09:35:36 +01:00
edde746 3a76754af9 feat: custom GLSL shader import
close #624
2026-03-04 08:47:40 +01:00
edde746 73eeac35a8 fix: disable async codec queueing 2026-03-04 07:53:13 +01:00
edde746 18abcef8a2 fix: offload large UTF-8 decoding to background isolate
Prevents ANR when Dio's responseDecoder synchronously decodes large API
responses on the main thread. Responses >50KB use compute(). Also caches
MediaCodecList query results in ExoPlayerCore companion object.
2026-03-04 07:42:26 +01:00
edde746 85800abf9f fix: disable tunneling for video codecs without tunneling support 2026-03-04 07:27:02 +01:00
edde746 2b72327013 fix: hide metal layer when window is occluded 2026-03-04 05:06:25 +01:00
edde746 cc86afb31d fix: sparkle update detection and startup hang 2026-03-04 01:09:35 +01:00
edde746 efac1a9f28 fix: watch together stream use after close 2026-03-04 00:20:48 +01:00
edde746 a9e4091500 fix: disable http breadcrumbs for sentry 2026-03-04 00:02:51 +01:00
edde746 891c4f8c32 fix: reduce currently-airing program contrast
close #622
2026-03-03 23:40:07 +01:00
edde746 96f7bd431c fix: ExoPlayer logs never reaching Dart log output
setLogLevel silently no-oped because initialized was false at call time.
emitLog gated all levels behind debugLoggingEnabled which was never set.
2026-03-03 23:23:06 +01:00
edde746 cd2ab9d9cd refactor: deduplicate shared patterns, replace hardcoded colors 2026-03-03 22:43:00 +01:00
edde746 8f3d52142d fix: watch together sync bugs and code quality
- Reset _firstPlayCompleted on detach so episode switches wait for peers
- Remove duplicate host join announcement from sync manager
- Use dedicated isPlaying field in sessionConfig with legacy fallback
- Replace Future.delayed with cancellable Timer to prevent sync indicator flicker
- Make Participant fields final and constructor const
2026-03-03 21:41:32 +01:00
edde746 cb7de47aed fix: guard ScrollController.position access in HorizontalScrollWithArrows
Prevents "Too many elements" StateError on Android TV when the controller
temporarily has multiple positions during widget rebuilds.
2026-03-03 20:45:38 +01:00
edde746 174c78bf67 fix: handle connectivity_plus PlatformException on Windows 2026-03-03 20:13:17 +01:00
edde746 19c36ca340 fix: normalize Sentry release version across platforms 2026-03-03 20:02:07 +01:00
github-actions[bot] b0432ece86 chore: update cask to 1.24.1 2026-03-03 18:39:39 +00:00
github-actions[bot] a009c6db93 chore: bump version to 1.24.1 2026-03-03 18:18:29 +00:00
edde746 e60b8d13b9 fix: improve error reporting data sanitization 2026-03-03 19:16:33 +01:00
edde746 1b673743b2 fix: handle int end-file reason from mpv on Windows/Linux 2026-03-03 19:00:32 +01:00
edde746 34e8c179fe fix: guard PiP calls on unsupported platforms 2026-03-03 19:00:32 +01:00
edde746 33d5760930 fix: uncommend play store release 2026-03-03 19:00:32 +01:00
github-actions[bot] 77ec4cc5c8 chore: update cask to 1.24.0 2026-03-03 17:02:12 +00:00
edde746 c8e6cac00c bump mpv windows to 20260303 2026-03-03 17:18:57 +01:00
github-actions[bot] 35fc0334bc chore: bump version to 1.24.0 2026-03-03 16:08:36 +00:00
edde746 c6ace690cb refactor: clean up download code duplication 2026-03-03 16:31:02 +01:00
edde746 7a979bed2f fix: harden download callbacks against stale status events
Guard _onDownloadFailed, _onDownloadPermanentlyFailed, and cancel
handler against overwriting completed downloads. Add
resumeFromBackground() for iOS background transitions.
2026-03-03 15:20:13 +01:00
edde746 e46bd71fa7 fix: prevent completed downloads from restarting on app launch
Race condition between trackTasks() completion callbacks and the orphan
scan caused completed items to be re-queued on every app restart (#616).
2026-03-03 15:02:40 +01:00
edde746 c98010234f fix: warnings 2026-03-03 14:30:59 +01:00
edde746 02e175e4d3 feat: replace rustrak with glitchtip 2026-03-03 14:27:11 +01:00
edde746 013bcfbece fix: library continue watching hidden
close #615
2026-03-03 12:17:37 +01:00
edde746 ebf2d1e516 fix: shorten nav labels
close #612
2026-03-03 12:13:43 +01:00
edde746 4bce668df6 fix: asymmetric divider in track sheet on landscape 2026-03-03 12:04:03 +01:00
edde746 c64c7defc3 fix: disable session tracking 2026-03-03 11:05:54 +01:00
edde746 1629801074 feat: add swipe-up content strip for mobile video controls 2026-03-03 11:03:31 +01:00
edde746 cd36e3acb0 feat: switch crash reporting from BugSink to Rustrak 2026-03-03 09:19:25 +01:00
edde746 7001032e51 feat: combine audio & subtitle track sheets into one 2026-03-03 07:16:45 +01:00
edde746 3a0bac4446 docs: add winget install option to readme 2026-03-03 06:35:15 +01:00
edde746 1c31f0effa fix: request audio focus before player init guard 2026-03-02 23:12:00 +01:00
edde746 01e61c590a fix: tighten startup connection timeouts for dead servers 2026-03-02 23:09:09 +01:00
edde746 a00e2b78d6 feat: replace mpv config UI with raw text editor 2026-03-02 23:06:05 +01:00
edde746 b5904bc477 fix: auto-retry large downloads after native retries exhausted
Increase native retries 3→5 and add app-level auto-retry (3 rounds,
30s delay) so large downloads that fail with "unexpected end of stream"
recover automatically. 404s fail immediately without retry.
2026-03-02 21:43:01 +01:00
edde746 47f2afb665 feat: bottom sheet polish 2026-03-02 21:24:53 +01:00
edde746 3b2e278868 fix: hide redundant items in context menu 2026-03-02 20:42:47 +01:00
edde746 8baa84c06f fix: use player.state.track for selected subtitle check 2026-03-02 19:25:13 +01:00
edde746 92b589213f fix(ci): add libcurl4-openssl-dev for Linux builds 2026-03-02 19:21:26 +01:00
edde746 94395feaba feat: implement sub-visibility toggle
Closes #597
2026-03-02 19:07:56 +01:00
edde746 c372920965 fix: resolve out-of-scope settingsService in video player 2026-03-02 18:26:05 +01:00
edde746 5ab6af1b02 feat: respect system 24h time format setting
Closes #605
2026-03-02 18:19:52 +01:00
edde746 34252b9ba7 fix: persist aspect ratio and shader settings
Closes #602, closes #603
2026-03-02 18:19:46 +01:00
edde746 8d3f448fdf feat(macos): add picture-in-picture support 2026-03-02 18:19:36 +01:00
edde746 7ebbfb9ef7 fix(i18n): add missing pip keys 2026-03-02 14:31:40 +01:00
edde746 a008f86ee2 feat(ios): add picture-in-picture support
close #44
2026-03-02 14:06:11 +01:00
edde746 5f1c51ff6c fix: skip specials in playback order
close #601
2026-03-02 07:32:20 +01:00
edde746 229d6b24e1 feat: crash log reporting 2026-03-02 07:29:21 +01:00
edde746 9dc0654225 fix(android): prevent dispatchWindowVisibilityChanged NPE during disposal 2026-03-02 06:10:00 +01:00
edde746 36277076bd fix(android): cap demuxer buffers + sync mpv dispose 2026-03-02 02:30:48 +01:00
edde746 f96ef0740d fix(android): move JSON parsing off main thread 2026-03-02 02:24:08 +01:00
edde746 6bee1a6c38 fix(android): add opensles audio fallback 2026-03-02 02:05:24 +01:00
edde746 0dbba6439d fix: hide hero carousel indicators in dpad mode
close #600
2026-03-02 01:50:51 +01:00
edde746 7ac888cd46 fix(windows): installer norun arg 2026-03-01 20:10:03 +01:00
github-actions[bot] 88f4ae9987 chore: update cask to 1.23.0 2026-03-01 16:11:23 +00:00
edde746 938291dbf6 bump mpvkit 2026-03-01 16:55:59 +01:00
edde746 f5715987fc feat: migrate iOS to scene lifecycle 2026-03-01 15:06:45 +01:00
edde746 7c0e86c3cf bump mpvkit 2026-03-01 13:59:44 +01:00
github-actions[bot] eae40938e0 chore: bump version to 1.23.0 2026-03-01 12:12:26 +00:00
edde746 9c7cb7439f feat: add winget package manager support 2026-03-01 13:11:11 +01:00
edde746 3bf7ff3d48 feat: improve LiveTV guide visual contrast and polish
close #494
2026-03-01 12:24:56 +01:00
edde746 138c8f9fd8 feat: auto picture-in-picture
close #527
2026-03-01 10:52:31 +01:00
edde746 3a5cab956d refactor: extract shared Android utilities from player cores 2026-03-01 10:40:59 +01:00
edde746 796db94896 remove unused sliver_adaptive_media_builder 2026-03-01 10:08:17 +01:00
edde746 d1dacae581 feat: show server name in search results
close #515
2026-03-01 09:24:53 +01:00
edde746 a62a01b9c3 feat: bridge ExoPlayer logs to Dart + device info in logs screen
ExoPlayerCore emitLog() forwards native diagnostics (init, tracks,
tunneling, watchdog, errors, framerate, audio focus) to Dart via the
existing log-message event when debug logging is enabled. URIs are
redacted before forwarding. setLogLevel method channel wires into the
existing debug toggle in video_player_screen.

Logs screen now shows a device info header (app version, OS, model,
TV mode) and includes it in copy/upload output.
2026-03-01 04:59:35 +01:00
edde746 ea9e1a3dc6 fix: bypass IME stage for dpad events 2026-03-01 04:59:35 +01:00
edde746 54ceee18a6 fix: remove alpha 0.999 hack from mpv SurfaceView
No longer needed since Flutter uses RenderMode.texture (TextureView),
which composites above SurfaceView naturally without overlay conflicts.
2026-03-01 04:02:56 +01:00
edde746 d0f2122944 feat: add tunneled playback setting + frame watchdog for HDR black screen
Adds a user-facing toggle for MediaCodec tunneling (Android/ExoPlayer)
and a rendered-frame watchdog that auto-falls back to MPV when ExoPlayer
produces 0 video frames after 8 seconds of audio playback.
2026-03-01 04:02:36 +01:00
edde746 1d739c74ec fix: use universal APK for Amazon Appstore
Amazon Appstore doesn't auto-target by ABI like Google Play,
so split APKs could serve the wrong architecture to devices.
2026-03-01 03:47:46 +01:00
edde746 5dfc5af4c5 fix: only blur episode thumbnails
close #595
2026-03-01 03:01:22 +01:00
edde746 8a5f1ddea9 feat: add audio normalization toggle (MPV loudnorm filter) 2026-03-01 02:49:48 +01:00
edde746 bbfe7cf783 fix: use explicit mediacodec hwdec chain on android 2026-03-01 02:46:50 +01:00
edde746 b78bc3e869 fix: only show timeline thumbnail on direct timeline interaction 2026-02-28 19:48:46 +01:00
edde746 2405cd179b fix: use forked libass-android with font buffering fix 2026-02-28 19:00:55 +01:00
edde746 fa9c5afeb8 fix: force FFmpeg for FLAC audio decoding 2026-02-28 15:24:31 +01:00
edde746 0e84ce9166 fix: desktop context menu overflow 2026-02-28 15:00:59 +01:00
edde746 9f81671603 fix: suppress repeated android log spam from MPV surface and stats polling
- Deduplicate android-surface-size updates with lastSurfaceSize cache
- Short-circuit ensureFlutterOverlayOnTop after initial application
- Remove deprecated cache-used property query
- Skip unavailable MPV properties on Android (display-fps, HDR metadata)
- Gate video-dependent stats queries behind hasVideo check
2026-02-28 15:00:29 +01:00
edde746 15e1f0b9e2 fix: use mediacodec on android
close #593
2026-02-28 12:35:43 +01:00
edde746 014f9456f6 fix: defer view removal to avoid AOSP dispatchWindowVisibilityChanged NPE 2026-02-28 10:23:28 +01:00
edde746 1bb4adfcf1 fix: don't pause playback on duckable audio focus loss
close #592
2026-02-28 09:22:13 +01:00
edde746 08399e5d37 feat: respect server collection mode in library browse
close #580
2026-02-28 07:06:48 +01:00
edde746 48c9dcae1b fix: apply hide spoilers setting to hero section
close #588
2026-02-28 06:18:11 +01:00
edde746 078f6b29d5 fix: recalculate video surface size on orientation change
close #587
2026-02-28 06:16:52 +01:00
edde746andGitHub 60d1431443 Merge pull request #538 from micahmo/feature/expand-episodes
Allow episode descriptions to be expanded
2026-02-28 05:48:22 +01:00
Micah Morrison 17182e334f Merge remote-tracking branch 'upstream/main' into feature/expand-episodes 2026-02-27 22:40:28 -05:00
Micah Morrison 5986ac6c79 Adjust expander pill alignment with text when small 2026-02-27 22:40:24 -05:00
github-actions[bot] 80dc5ffdc5 chore: update cask to 1.22.0 2026-02-27 23:13:20 +00:00
github-actions[bot] 0449be7aa0 chore: bump version to 1.22.0 2026-02-27 22:57:55 +00:00
Micah Morrison c02f84dba0 Merge remote-tracking branch 'upstream/main' into feature/expand-episodes 2026-02-27 16:47:51 -05:00
edde746 a6119414ca Merge branch 'fix-plex-notifications' 2026-02-27 22:20:12 +01:00
edde746 4929e7d42b fix: hardcode app name in connection probe headers 2026-02-27 22:19:24 +01:00
edde746 18614022c0 feat: auto-dismiss skip segment buttons
closes #584
2026-02-27 22:13:03 +01:00
edde746 389a9622c3 fix: prevent OOM crash from infinite focus reclaim loop
Add re-entrancy guard to VideoPlayerScreen._onScreenFocusChanged()
and replace busy-wait spin loop with Completer in MediaDetailScreen.
2026-02-27 21:23:31 +01:00
edde746 4cebff4367 move debug output 2026-02-27 21:19:52 +01:00
edde746 3103cb5ee1 fix: harden offline playback and exoplayer fallback 2026-02-27 21:02:30 +01:00
edde746 7a0a911cd9 fix: prevent ASS subtitle stretching
close #579
2026-02-27 20:33:48 +01:00
edde746 03d62d2e2b fix: handle corrupted download paths missing leading slash 2026-02-27 19:05:05 +01:00
edde746 5ff5441baa fix: map ssa subtitle codec to .ass extension
close #569
2026-02-27 16:51:49 +01:00
edde746 c1e9911841 chore: update MPVKit to 0.41.0 on iOS/macOS 2026-02-27 16:41:27 +01:00
edde746 00667fe8b8 fix: add const constructors and remove unused imports 2026-02-27 15:43:34 +01:00
edde746 ab2f8cf6ff fix: normalize corrupted download paths on startup 2026-02-27 15:43:34 +01:00
edde746 edb285a279 feat: cache BIF file for instant preview thumbnails
close #565
2026-02-27 15:30:29 +01:00
edde746 11377362cb fix: duplicate hero tag error in logs upload dialog 2026-02-27 15:26:49 +01:00
edde746 1cdf1890cf fix: download playback issues (doubled path, audio language, spinner) 2026-02-27 15:26:49 +01:00
edde746 9e0c3e7b68 fix: improve delete-from-server button safety
Rename "Delete" to "Delete from server" with distinct icon and
always-red styling to prevent accidental server deletions.

Closes #568
2026-02-27 14:49:47 +01:00
edde746 b549432250 ci: exclude generated .g.dart files from sonar 2026-02-27 14:34:06 +01:00
edde746 b100c356fc ci: add flutter pub get to sonar workflow 2026-02-27 14:33:47 +01:00
edde746 045295b4c1 ci: add sonar project properties 2026-02-27 14:29:36 +01:00
edde746 ad9556e484 ci: add SonarQube workflow 2026-02-27 14:27:10 +01:00
edde746 7f03c15779 fix: restore FocusTheme import in libraries screen 2026-02-27 12:53:21 +01:00
edde746 cc30bee83a refactor: extract FocusableActionBar widget for reusable app bar actions
Replace duplicated focusable action button pattern across 8 screens with
a shared FocusableActionBar widget that handles focus nodes, D-pad
navigation, back key, and focus decoration automatically.
2026-02-27 11:55:19 +01:00
edde746 8559037a50 fix: logs screen d-pad navigation 2026-02-27 11:37:11 +01:00
edde746 732c09eec1 fix: cancel status stream subscription on dispose
Closes #571
2026-02-27 09:11:16 +01:00
edde746 602982d426 fix: remove low memory warnings during playback
Closes #576
2026-02-27 08:53:38 +01:00
edde746 7472e3a2f7 fix: broken imports 2026-02-26 14:57:37 +01:00
Matt Vogel 6eeb484c30 Pass persistent client UUID through auth screen login path
The auth screen was calling connectAndInitialize without a clientIdentifier,
causing MultiServerManager to fall back to a throwaway timestamp ID for all
probe requests during first login. This meant Plex registered a new device on
every login, not just the first ever install.
2026-02-26 08:21:06 -05:00
Matt Vogel e9218e0a3d Fix duplicate Plex notifications and Flutter app name on login
Connection probe requests in testConnectionWithLatency were sent without
X-Plex-Client-Identifier, X-Plex-Product, or X-Plex-Device-Name headers.
Plex treated each anonymous probe as a new unknown device and fired a
"New Device" notification for every server tested (one per shared/owned
server), while displaying "Flutter" as the device name from the HTTP
user-agent.

Pass clientIdentifier through findBestWorkingConnection and all connection
test helpers so every probe request identifies itself as "Plezy" with the
persistent client UUID. This prevents spurious notifications and ensures
the device shows the correct app name in Plex's device list.

https://claude.ai/code/session_01V5VraujkNmk5GGPLyZ33fN
2026-02-26 08:21:06 -05:00
edde746 4588457319 refactor: consolidate files 2026-02-26 13:41:51 +01:00
edde746 e489a97847 fix: throttle demuxer-cache-time updates 2026-02-26 13:12:25 +01:00
edde746 2b5923d80b feat: square art in hero sections 2026-02-26 13:00:55 +01:00
edde746 5cf5b2f0a0 fix: mpv destroy/create ANR 2026-02-26 12:56:02 +01:00
edde746 a56ef0e3ca fix: throttle cache state parsing 2026-02-26 12:28:42 +01:00
edde746 8eda892b68 feat: themed splash screen with status messages 2026-02-26 11:55:45 +01:00
edde746 4b6c82b071 fix: hide alpha jump bar for small libraries 2026-02-26 11:55:45 +01:00
edde746 79350b8d71 feat: set avfoundation as preferred audio output on macOS 2026-02-26 11:55:45 +01:00
edde746 a5fa8a4c99 fix: don't clear buffer state on playback restart 2026-02-26 11:55:45 +01:00
edde746 a38aac7829 fix: artwork changing not working
- Use PUT instead of POST and singular element path (art/poster) to
  match Plex Web API behavior
- Set content type to application/octet-stream for binary uploads
- Add GestureDetector for mouse/touch tap support in artwork picker
- Always refresh detail screen metadata after returning from edit
2026-02-26 11:55:45 +01:00
edde746 414e5804eb feat: add hide spoilers setting for unwatched episodes 2026-02-26 11:55:45 +01:00
github-actions[bot] cbf9913e8a chore: update cask to 1.21.3 2026-02-26 04:10:17 +00:00
github-actions[bot] 8f24bd478a chore: bump version to 1.21.3 2026-02-26 03:32:43 +00:00
edde746 a32422bb5e chore: remove unused formatRelativeTime 2026-02-26 04:30:48 +01:00
edde746 e25fb4c10f fix: ExoPlayer resume position lost on tunneling change 2026-02-26 04:19:17 +01:00
edde746 5740d93a35 fix: download from homepage failing 2026-02-26 03:41:27 +01:00
edde746 98776b40f5 fix: show sync controls as compact top bar
close #548
2026-02-26 03:41:19 +01:00
edde746 3418241c04 fix: disable tunneling for FFmpeg-only audio codecs 2026-02-26 02:14:22 +01:00
edde746 659b59d450 fix: remove companion remote connection history 2026-02-26 01:08:46 +01:00
edde746 acf91107ad fix: split combined recently added hubs by library
closes #552
2026-02-26 00:30:23 +01:00
edde746 3279bc7578 fix: sanitize dots in download filenames
close #556
2026-02-26 00:02:14 +01:00
edde746 383351d769 fix: detect invalid tokens and prevent startup hangs
close #553
2026-02-25 23:59:19 +01:00
edde746 0f4920cc18 fix: reduce ExoPlayer buffer limits
close #546
2026-02-25 23:43:43 +01:00
edde746 3460fa8b32 fix: download retry failing with metadata cache miss
close #555
2026-02-25 23:25:10 +01:00
edde746 bf3f5282f2 fix: skip intro button staying on screen
close #550
2026-02-25 23:03:07 +01:00
edde746 c480e44e0e fix: skeleton card visibility and layout 2026-02-25 22:54:15 +01:00
edde746 728c4854a5 feat: sparse-map pagination for library browse 2026-02-25 18:14:48 +01:00
edde746 6188d21c3d perf: limit concurrent image transcode requests 2026-02-25 17:01:43 +01:00
edde746 88d7e2d319 feat: add audio passthrough toggle for desktop 2026-02-25 16:38:58 +01:00
edde746 fc5fcbb0db fix: google tv virtual remote dpad 2026-02-25 16:13:53 +01:00
edde746 93f693c5c4 fix: macos folder picker entitlement 2026-02-25 15:59:06 +01:00
edde746andGitHub aa6a5ec234 docs: update HDR platform support info 2026-02-25 15:18:39 +01:00
github-actions[bot] 4f4192b261 chore: update cask to 1.21.2 2026-02-25 09:03:19 +00:00
github-actions[bot] cb6da03c10 chore: bump version to 1.21.2 2026-02-25 08:24:36 +00:00
edde746 b193a23524 fix: video stuck on still frame after long pause
close #536
2026-02-25 08:17:14 +01:00
edde746 cb39945a9d fix: watch together clock drift
close #534
2026-02-25 07:50:17 +01:00
edde746 45e792e3ab fix: ESC exits fullscreen without closing video player
close #533
2026-02-25 07:17:24 +01:00
Micah Morrison 8acb777f65 Allow episode descriptions to be expanded 2026-02-24 21:58:35 -05:00
edde746 50660013cc fix: restore tap/click handling in folder tree view 2026-02-24 23:54:42 +01:00
edde746 e0489b68d5 fix: use theme colors in video control sheets for light mode support 2026-02-24 23:40:08 +01:00
edde746 af41d937c3 fix: remove DVR recording features (plex pass)
close #530
2026-02-24 23:13:38 +01:00
edde746 238391b886 fix: appcast single item with release notes 2026-02-24 18:07:32 +01:00
edde746 1eec3d280b fix: WinSparkle platform filtering and version display 2026-02-24 17:42:41 +01:00
github-actions[bot] 8ed45e309c chore: bump version to 1.21.1 2026-02-24 16:06:25 +00:00
edde746 2f488bd395 fix: disable ambient lighting in picture-in-picture mode
closes #528
2026-02-24 17:05:41 +01:00
edde746 d40890c344 fix: restore long press on seasons and episodes 2026-02-24 17:02:12 +01:00
github-actions[bot] de5566fb14 chore: update cask to 1.21.0 2026-02-24 13:30:45 +00:00
github-actions[bot] 9e8bb9909d chore: bump version to 1.21.0 2026-02-24 13:13:38 +00:00
edde746 eea98e0cc9 fix: pass version to installer, silent update, launch after install 2026-02-24 14:05:46 +01:00
edde746 6af3a2974e fix: CRLF in windows signature metadata, use generic os 2026-02-24 13:59:44 +01:00
edde746 da64c69724 fix: inline EdDSA pubkey as resource string 2026-02-24 13:56:38 +01:00
edde746 d044ae902c fix: CRLF in base64 key on windows CI 2026-02-24 13:30:15 +01:00
edde746 350102e3cb fix: write raw key to avoid PEM indentation issue 2026-02-24 12:50:46 +01:00
edde746 6674ee3551 fix: lightweight windows EdDSA signing in CI 2026-02-24 12:30:56 +01:00
edde746 eda7f6515e fix: override auto_updater_windows to fork with WinSparkle 0.9.2 2026-02-24 12:11:46 +01:00
edde746 145ff88ccf fix: use dart-lang/setup-dart for windows signing 2026-02-24 12:00:47 +01:00
edde746 070c8e336d feat: switch to auto_updater fork with WinSparkle 0.9.2 EdDSA 2026-02-24 11:57:34 +01:00
edde746 78049c981b fix: black screen when closing manage libraries sheet 2026-02-24 11:05:55 +01:00
edde746 490066318c fix: CI secrets condition in workflow 2026-02-24 10:16:39 +01:00
edde746 4083837c3b feat: still watching prompt on sleep timer expiry 2026-02-24 10:08:50 +01:00
edde746 3fc1540f41 feat: make companion remote dialog use focusablebutton 2026-02-24 04:56:33 +01:00
edde746 403df31907 feat: native auto-update
close #521
2026-02-24 04:04:02 +01:00
edde746 d1d5b808bb fix: reduce widget tree depth 2026-02-24 02:40:04 +01:00
edde746 9528b8f61a feat: multi-IP QR code for companion remote 2026-02-24 02:31:24 +01:00
edde746 2276750704 fix: memory-aware buffer limits 2026-02-24 00:56:09 +01:00
edde746 a1a030a130 fix: create render context before file load 2026-02-24 00:07:09 +01:00
edde746 3d9c6b203f fix: isolated EGL context for mpv rendering 2026-02-23 18:20:08 +01:00
edde746 e23f472d78 refactor: centralize globalKey construction via buildGlobalKey() 2026-02-23 17:53:20 +01:00
edde746 ef2c464dd4 fix: GL proc address detection 2026-02-23 17:48:42 +01:00
edde746 778ac50116 perf: fast offline startup
close #511
2026-02-23 14:09:13 +01:00
edde746 8f50da4a75 fix: resolve all dart analyze warnings
- Migrate RadioListTile to RadioGroup API (Flutter 3.32+)
- Guard BuildContext usage across async gaps
- Use const BorderRadius.all / EdgeInsets.all constructors
- Extract nested ternaries into helpers
- Prefer .first over [0], ??= over if-null assignment
- Prefix unused FocusNode params with _
- Add library directive for dangling doc comments
2026-02-23 13:50:56 +01:00
edde746 8918bdc93e fix: add OverlaySheetHost to desktop/TV navigation path 2026-02-23 13:11:11 +01:00
edde746 a599920ab4 fix: overlay sheet theme and scope on mobile 2026-02-23 13:00:42 +01:00
edde746 4095cc27e1 perf: reduce redundant metadata API requests 2026-02-23 11:43:42 +01:00
edde746 1eb88e23f5 perf: cache-first metadata fetching for playback 2026-02-23 10:51:25 +01:00
edde746 edbe2a06be refactor: deduplicate sheet, key handler, and service patterns 2026-02-23 10:25:57 +01:00
github-actions[bot] e9307c87f0 chore: update cask to 1.20.0 2026-02-23 08:08:52 +00:00
edde746 964b89aa67 fix(windows): release gamepad handles on window blur 2026-02-23 08:05:55 +01:00
edde746 3670383fde fix(desktop): profile switch on every window focus
close #517
2026-02-23 06:36:49 +01:00
github-actions[bot] 1855549ccb chore: bump version to 1.20.0 2026-02-23 04:48:18 +00:00
edde746 26ff55e005 fix(android): auto buffer size to prevent OOM 2026-02-23 05:42:04 +01:00
edde746 6916b386eb fix(android): SurfaceControl crash on player dispose 2026-02-23 05:28:10 +01:00
edde746 1860a1cea6 feat: dpadnavigation for folder tree view
close #513
2026-02-23 03:42:07 +01:00
edde746 7802beb41b feat: play/shuffle folder contents
close #514
2026-02-23 02:19:57 +01:00
edde746 4eb55885f7 feat: metadata editing
close #338
2026-02-22 17:56:13 +01:00
edde746 03fc1c1109 fix: auto-focus first content item on settings screens in dpad mode 2026-02-22 15:58:10 +01:00
edde746 d709d638c7 fix: use dpad controls for settings dialogs in keyboard nav mode 2026-02-22 15:20:16 +01:00
edde746 7f8d4c7946 fix: dpad focus for dialogs and buttons 2026-02-22 14:50:59 +01:00
edde746 1536feb034 fix: dpad focus on pushed screens
close #510
2026-02-22 11:46:47 +01:00
edde746 83c0cce7f3 fix: ignore gamepad input when window is unfocused
close #509
2026-02-22 10:29:52 +01:00
edde746 389a4dcc25 fix: android debug info path 2026-02-22 05:42:30 +01:00
github-actions[bot] 0aee098d46 chore: bump version to 1.19.0 2026-02-22 04:13:36 +00:00
edde746 3289ce0fbc feat: fallback skip markers from chapter titles 2026-02-22 04:34:36 +01:00
edde746 8ef0d2e25c feat: retard proof QR code 2026-02-21 10:35:48 +01:00
edde746 c4a51e0fb9 fix: persist debug symbols for symbolication 2026-02-21 05:45:16 +01:00
edde746 9819c4f495 fix: move hub/onDeck API processing to isolates 2026-02-21 05:34:06 +01:00
edde746 1ebc2a85d1 fix: move cache JSON ops to isolates 2026-02-21 05:00:14 +01:00
edde746 0159c18497 feat: discontinuous buffer ranges on timeline 2026-02-21 04:50:10 +01:00
edde746 0b1b18fd35 fix: macOS playback power management 2026-02-21 01:32:17 +01:00
edde746 4dc7101f39 fix: remove unused MediaGridSliver widget 2026-02-20 22:38:55 +01:00
edde746 3bfc24bf9b feat: persist ambient lighting and make it mutually exclusive with shaders
close #499
2026-02-20 22:33:00 +01:00
edde746 d307f8c99d fix: prompt PIN for current profile on app open
close #485
2026-02-20 22:28:11 +01:00
edde746 ec054fce46 feat: add View All card and dpad focus to hub detail
close #474
2026-02-20 22:10:52 +01:00
edde746 b25df3b411 feat: embed DUCET collation ranks for alpha-jump sorting
close #498
2026-02-20 18:05:10 +01:00
edde746 57bdb3997e fix: remove unused import in rating_bottom_sheet 2026-02-20 10:00:02 +01:00
edde746 6647cf25b0 fix: amazon appstore uploads 2026-02-20 09:58:03 +01:00
edde746 1e6a1af1cf feat: add user star ratings
close #411
2026-02-20 09:57:44 +01:00
edde746 637a3e9e37 chore: bump media3 1.5.1 → 1.9.2, drop unused media3-session 2026-02-20 03:32:38 +01:00
edde746 ad4b23b18b fix: mpv dispose deadlock on wayland 2026-02-19 22:32:32 +01:00
edde746 582809427e fix: linux mpv dispose deadlock on wayland 2026-02-19 21:50:29 +01:00
edde746 df09d2249d fix: add missing setLogLevel handler to iOS MPV plugin 2026-02-19 21:22:08 +01:00
github-actions[bot] c2cca423d7 chore: update cask to 1.18.2 2026-02-19 10:49:51 +00:00
github-actions[bot] 0ba2ecd90a chore: bump version to 1.18.2 2026-02-19 10:34:06 +00:00
edde746 60ef83bd3a fix: add missing setLogLevel handler to Android MPV plugin 2026-02-19 11:33:12 +01:00
edde746 89c7b79867 fix: use identifier as fallback key for EPG channels 2026-02-19 09:13:00 +01:00
edde746 bfe7d54dcf feat: add kBlurArtwork mode for store screenshots
Blurs all artwork and rotates vowels in metadata when enabled.
2026-02-19 05:45:46 +01:00
github-actions[bot] d9bfb73146 chore: bump version to 1.18.1 2026-02-19 04:10:20 +00:00
edde746 fc2aa53197 fix: only auto-focus overlay sheets in dpad mode 2026-02-19 01:55:45 +01:00
edde746 9bf9a6f23b fix: clear stale back-key flags on overlay sheet close 2026-02-19 00:39:44 +01:00
edde746 9e7c66f66a refactor: migrate bottom sheets to overlay system 2026-02-19 00:18:35 +01:00
edde746 63d711ae43 refactor: overlay-based bottom sheets for video player 2026-02-18 23:06:44 +01:00
edde746 7c651eb61f fix: cap ExoPlayer buffer size 2026-02-18 21:17:50 +01:00
edde746 3bba440e18 fix: enable largeHeap for ExoPlayer OOM 2026-02-18 19:13:40 +01:00
edde746 1f44ac6050 docs: add Live TV to readme 2026-02-18 16:35:06 +01:00
edde746 8d5b5d2e0c fix: guard against post-disposal stream controller access 2026-02-18 09:20:48 +01:00
edde746 aae1b1c45c refactor: clean up release script and fastlane configs 2026-02-18 09:15:20 +01:00
github-actions[bot] b74cacd660 chore: bump version to 1.18.0 2026-02-18 07:08:11 +00:00
edde746 1fc0d0458b fix: dpad back navigation for settings sub-screens 2026-02-18 08:06:48 +01:00
edde746 64c0c9979b fix: dpad focus and navigation for Live TV guide 2026-02-18 08:06:05 +01:00
edde746 b419ff5507 fix: custom dpad navigation for sidenav
close #479
2026-02-18 07:55:16 +01:00
edde746 f508013aa5 fix(ios): remove processing background mode 2026-02-18 06:51:44 +01:00
edde746 756eb8d6f0 feat: add ambient lighting effect
close #477
2026-02-18 06:51:20 +01:00
edde746 83e04b64da fix: correct D-pad focus navigation order on media detail screen 2026-02-18 03:30:04 +01:00
edde746andGitHub 408bf8577d Merge pull request #476 from Sphyix/playback-fix
setLogLevel macOS playback
2026-02-18 02:21:59 +01:00
Federico 90e8223c74 setLogLevel missing 2026-02-18 02:18:06 +01:00
edde746andGitHub b1377ea4a1 Merge pull request #473 from Sphyix/playback-fix
Fix playback on macOS
2026-02-18 01:20:57 +01:00
Federico 348aa69a50 Update Info.plist 2026-02-17 17:58:53 +01:00
edde746andGitHub 1913d49117 Merge pull request #471 from AmyJeanes/remove-continue-watching-mid-progress
fix: show 'mark as unwatched' for in progress items
2026-02-17 10:59:38 +01:00
edde746 2bc2c0a0ec feat: use FlTextureGL for Linux mpv video rendering 2026-02-17 08:55:29 +01:00
edde746 544fccf82d fix: update universal_gamepad 2026-02-17 07:51:18 +01:00
edde746 71bfd3ca2f fix: force LF line endings for shell scripts and Dockerfiles 2026-02-17 03:37:49 +01:00
edde746 f2f7bb3508 chore: bump universal_gamepad to 1.1.1 2026-02-17 03:37:03 +01:00
edde746 c98add8065 fix: resolve UI freezes during video playback on Steam Deck
- Default MPV native log level to "warn" instead of "v" (Linux/Windows),
  add setLogLevel method channel to raise it when debug logging is enabled
- Coalesce MPV render requests via atomic compare_exchange on needs_redraw_
- Clear redraw flag before render so new redraws queue during current frame
2026-02-17 03:11:52 +01:00
Amy Jeanes 56b7cb842e show mark as unwatched for mid progress items 2026-02-17 01:24:07 +00:00
edde746 223a5d2219 chore: bump os_media_controls 2026-02-17 01:21:07 +01:00
edde746 66611b9bc3 feat: dockerfile-based steam build with layer caching 2026-02-17 01:20:10 +01:00
edde746 35f56c8a80 feat: steam build script 2026-02-16 23:32:51 +01:00
edde746 653eee1453 feat: add steam deploy script 2026-02-16 21:56:47 +01:00
edde746 29f5dc00c4 feat: populate audio output device menu and group by backend 2026-02-16 21:56:22 +01:00
edde746 9d04833b3e fix: only consume nav keys in video player 2026-02-16 18:34:12 +01:00
github-actions[bot] a55b255d05 chore: update cask to 1.17.0 2026-02-16 16:20:30 +00:00
github-actions[bot] b29011c5a7 chore: bump version to 1.17.0 2026-02-16 15:07:07 +00:00
edde746 a61fca0588 perf: compact [propId, value] wire format for property events 2026-02-16 15:40:52 +01:00
edde746 c3b10d6c45 fix: fallback to external browser when Custom Tabs unavailable 2026-02-16 04:21:44 +01:00
edde746 3dde8334e0 fix: refresh home page when libraries are hidden/unhidden
close #465
2026-02-16 03:12:46 +01:00
edde746 23c4c400f0 feat: focus navigation for movie detail sections
close #464
2026-02-16 02:17:10 +01:00
edde746 53c94b14cc feat: add back button exit confirmation on Android TV
close #467
2026-02-16 01:22:48 +01:00
edde746 1770109ff9 fix: support touch input for sidebar expand/collapse
close #466
2026-02-16 00:01:44 +01:00
edde746 7d29d7ba45 chore: format 2026-02-15 23:13:33 +01:00
edde746 77c124b528 Merge branch 'trailers-extras' 2026-02-15 23:11:30 +01:00
edde746 90a40d034f refactor: reuse MediaCard for extras 2026-02-15 22:59:43 +01:00
Matt Vogel bb8bddd1a7 fix: reduce white space in trailers & extras row
Fixes excessive white space at the bottom of media containers in the
trailers & extras horizontal scroll:
- Add mainAxisSize.min to Column to prevent expansion
- Reduce container height from 200 to 160px to match content size
2026-02-15 15:09:45 -05:00
Matt Vogel 0bbcd854e4 feat: add trailers and extras support
Adds support for viewing and playing trailers and bonus content from Plex.

- Add getExtras() API method to fetch extras from Plex
- Add trailer/extras metadata fields (subtype, extraType, primaryExtraKey)
- Add play trailer button with film reel icon on media detail screen
- Add "Trailers & Extras" section below cast with horizontal scroll
- Support offline mode via cache fallback
- Preserve serverId/serverName for multi-server setups
2026-02-15 15:09:45 -05:00
edde746 07809b8037 fix: handle duplicate column in v8 migration 2026-02-15 18:48:52 +01:00
edde746 eaad505d96 fix: reduce main-thread pressure during playback 2026-02-15 18:35:51 +01:00
edde746 b62a3501d2 fix: SurfaceView ANR on Android 2026-02-15 18:10:46 +01:00
edde746 292c4b5d82 fix: reduce main-thread DB I/O blocking in downloads 2026-02-15 17:55:02 +01:00
edde746 04438c8e45 refactor: code quality & format 2026-02-15 04:07:09 +01:00
edde746 1641354055 fix: warnings 2026-02-14 22:58:16 +01:00
edde746 9184bb8d40 Merge branch 'live-tv'
# Conflicts:
#	lib/i18n/strings.g.dart
#	lib/i18n/strings_de.g.dart
#	lib/i18n/strings_en.g.dart
#	lib/i18n/strings_es.g.dart
#	lib/i18n/strings_fr.g.dart
#	lib/i18n/strings_it.g.dart
#	lib/i18n/strings_ko.g.dart
#	lib/i18n/strings_nl.g.dart
#	lib/i18n/strings_sv.g.dart
#	lib/i18n/strings_zh.g.dart
#	lib/screens/main_screen.dart
#	lib/services/plex_client.dart
#	lib/widgets/video_controls/desktop_video_controls.dart
2026-02-14 22:29:16 +01:00
edde746 1c7303d095 fix: download queue status 2026-02-14 22:22:50 +01:00
edde746 4fc98426ff feat: connection recovery on mobile resume and endpoint exhaustion 2026-02-14 22:11:00 +01:00
edde746 0d72c6c1a4 fix: external player on Android 11+ 2026-02-14 20:19:27 +01:00
edde746 fb9a1cd77e fix: downloaded media detail screen clear logo 2026-02-14 19:28:43 +01:00
edde746 6f027f1015 fix: notify season screen when download is deleted 2026-02-14 18:37:28 +01:00
edde746 86a989a2f2 fix: open downloaded videos in external player on Android 2026-02-14 18:26:05 +01:00
edde746 d986f0d2ea feat: migrate downloads to background_downloader
close #454
2026-02-14 18:02:49 +01:00
edde746 2278af8d83 fix: exit video player when sleep timer completes
close #456
2026-02-14 11:58:16 +01:00
edde746 b3ff48feca fix(tv): live playback and timeline keepalive
Disable MKV Cues seeking for live streams, fix timeline params.
2026-02-14 03:33:58 +01:00
edde746andGitHub 938e739ba7 Merge pull request #455 from micahmo/fix/delete-button-colors
Fix the colors of the delete buttons
2026-02-14 02:32:43 +01:00
Micah Morrison 336da4c110 Fix the colors of the delete buttons 2026-02-13 20:07:07 -05:00
edde746 fa06f23b42 fix(tv): guide UX fixes 2026-02-13 18:21:05 +01:00
edde746 fd615c237d fix: persist library browse filters across library switches 2026-02-13 17:52:31 +01:00
edde746 fd53acbb92 fix(tv): use channel key for tuning and EPG matching 2026-02-13 17:23:02 +01:00
edde746 f4d940af10 fix(tv): add diagnostic logging for multi-DVR issues
Also remove suspicious Uri.decodeComponent on lineup parameter.
2026-02-13 16:29:33 +01:00
edde746 a4d4e2e1f8 fix(tv): query all EPG providers for multi-DVR support 2026-02-13 14:16:44 +01:00
edde746 0791764de9 feat: lower minSdk to 25 2026-02-13 14:00:24 +01:00
edde746andGitHub 7eae5403cf Merge pull request #453 from micahmo/fix/episode-watched-status
Fix episode watched status
2026-02-13 13:12:03 +01:00
edde746andGitHub a414da76d2 Merge pull request #450 from micahmo/feature/chapter-tooltips
Show previous and next chapter names as tooltips
2026-02-13 13:09:26 +01:00
Micah Morrison db84bada31 Fix episode watched status 2026-02-12 19:52:08 -05:00
edde746 426f6ab6ba fix(tv): misc improvements 2026-02-13 00:01:54 +01:00
edde746 7745b5a2f8 fix(tv): focus 2026-02-12 21:23:12 +01:00
edde746 daff76363b refactor(tv): clean up bottom sheet 2026-02-12 18:29:49 +01:00
edde746 88aca7aad3 feat(tv): add actions bottom sheet for non-live schedule items 2026-02-12 18:09:43 +01:00
edde746 ca90600764 refactor(tv): tune live channel inside player screen 2026-02-12 17:47:51 +01:00
edde746 4aced4d9ee refactor(tv): use CustomAppBar on schedule and DVR screens 2026-02-12 17:04:39 +01:00
edde746 ac1dae25b8 feat(tv): add What's On tab with API-driven hubs and show schedule 2026-02-12 16:46:15 +01:00
edde746 fbb9982f44 feat(tv): add poster to program details, translate EPG strings 2026-02-12 14:57:43 +01:00
edde746 eb644c0194 fix(tv): hide seek/skip controls during live playback 2026-02-12 14:21:21 +01:00
edde746 80f26b07c0 feat(tv): inline EPG guide grid with provider endpoint discovery 2026-02-12 14:16:10 +01:00
edde746 2ae6385913 fix(tv): playback stopping 2026-02-12 11:21:00 +01:00
edde746 a1d78562d6 fix(tv): playback 2026-02-12 03:52:51 +01:00
edde746 df3f9ed8a0 fix: profile switch focus 2026-02-12 01:10:47 +01:00
Micah Morrison 2509cb8193 Show previous and next chapter names as tooltips 2026-02-11 17:43:25 -05:00
edde746 cc15e964d0 fix: remove unused import 2026-02-11 18:03:25 +01:00
edde746 ee54259e4b fix: pass non-navigation keys through 2026-02-11 18:03:11 +01:00
edde746 c651fe08f4 fix: re-probe offline servers on connectivity recovery 2026-02-11 18:02:22 +01:00
edde746 403b1f6776 feat: live tv 2026-02-11 16:27:49 +01:00
edde746 5d40468dc2 feat: apply library density to hub rows and reduce grid sizes
close #433
2026-02-11 15:22:07 +01:00
edde746 5c1e40c953 fix: lower minimum subtitle font size to 10 2026-02-11 15:05:05 +01:00
edde746 ad06ef2bef fix warning 2026-02-11 15:00:58 +01:00
edde746 03907db6c4 feat: external player support
close #388
2026-02-11 14:59:52 +01:00
edde746 45e72e0ad9 fix: unmaximize window before entering fullscreen on Windows 2026-02-11 09:29:15 +01:00
edde746 3ade961af3 feat: 4-digit PIN input for profile switcher 2026-02-11 01:10:53 +01:00
edde746 9c6f18e3b8 fix: TV back button sidenav, companion remote focus, profile focus steal 2026-02-11 00:58:16 +01:00
edde746 f33f58339d fix: watch together bugs, TV focus issues, system locale default
- Fix guest controls locked on join (use reactive context.select)
- Fix Google TV back button when controls hidden (focus recovery + global fallback)
- Fix profile switch screen focus lost on TV (explicit focus request)
- Add 15s host reconnect grace period with reconnecting overlay
- Add participant join/leave notification toasts
- Default to system language on first launch via findDeviceLocale()
2026-02-11 00:04:09 +01:00
edde746 df844757ec feat: relay health check on Watch Together screen 2026-02-10 22:38:47 +01:00
edde746 6e9b78e5b5 fix: missing translations, simplify translations 2026-02-10 21:37:27 +01:00
edde746 68c169891c feat: mouse wheel volume control on video player 2026-02-10 18:34:47 +01:00
edde746 7234da5b64 feat: skip intro/credits keyboard shortcut
close #419
2026-02-10 18:11:32 +01:00
edde746 54c985d113 fix: use wakelock_plus fork 2026-02-10 17:43:58 +01:00
edde746 94814c92b9 fix: hero auto-scroll timer leak 2026-02-10 12:58:19 +01:00
edde746 e80d1f7132 Merge branch 'companion-remote'
# Conflicts:
#	lib/i18n/strings.g.dart
2026-02-10 12:47:41 +01:00
edde746 451cf8ae59 fix: auto-hide cursor in keyboard mode 2026-02-10 12:47:06 +01:00
edde746 d1af24e0a7 feat: player-aware companion remote with syncState, track cycling 2026-02-10 12:32:00 +01:00
edde746 5c3fbfdff8 fix: remote dialog issues and optimize command protocol 2026-02-10 09:17:55 +01:00
edde746 660267b504 fix: companion remote discovery leak, reconnect, and auth hardening
- Dispose old discovery service before creating new one in loadRecentSessions()
- Host waits for client reconnect instead of calling joinSession
- Clear stale error messages on successful reconnect
- Rate limit auth attempts (5 tries, 30s lockout)
- Use Random.secure() for peer ID
- Extract shared ACK helper methods
2026-02-10 09:02:22 +01:00
edde746 0fd365a910 refactor: simplify watch together buffering/ready system 2026-02-10 07:03:35 +01:00
edde746 e586360e39 fix: watch together same-episode replay blocked 2026-02-10 06:30:33 +01:00
edde746 075a4a45c8 fix: watch together guest losing sync when host switches episodes
close #431
2026-02-10 01:41:28 +01:00
Matt Vogel e30c0b4370 Migrate companion remote to WebSocket 2026-02-09 18:45:10 -05:00
edde746 2de92e660d feat: adjustable subtitle position
close #426
2026-02-09 21:22:19 +01:00
edde746 4d50c778ad more linux fixes 2026-02-09 20:48:35 +01:00
Matt Vogel 199d634cb2 Migrate companion remote models to @JsonSerializable 2026-02-09 14:26:51 -05:00
Matt Vogel 972ded5b0c Fix remote session dialog, peer service, and mobile remote screen 2026-02-09 14:20:32 -05:00
Matt Vogel 372767b142 Add Companion Remote for mobile-to-desktop control 2026-02-09 14:19:54 -05:00
edde746 ffe2292d11 fix(linux): resolve transitive deps 2026-02-09 19:48:22 +01:00
edde746 4dfcba85c0 fix: find libmpv.so in multiarch install path 2026-02-09 19:10:54 +01:00
edde746 760be7636a fix: playback speed having no effect on Android TV
Closes #424
2026-02-09 18:38:40 +01:00
edde746 c148cf32db fix: use absolute PKG_CONFIG_PATH in Linux CI 2026-02-09 18:31:13 +01:00
edde746 32735f38b3 feat: build libmpv from source in CI 2026-02-09 18:13:36 +01:00
edde746andGitHub cae1ce0ee5 Merge pull request #423 from micahmo/feature/thumbnails
Add support for showing thumbnails when navigating timeline
2026-02-09 17:39:27 +01:00
Micah Morrison 1654c48a34 Add support for showing thumbnails when navigating timeline 2026-02-09 10:43:03 -05:00
edde746 0dc1797eb9 fix: bundle libmpv 2026-02-09 14:16:26 +01:00
edde746 cf1312f0f2 chore: upgrade Android Gradle Plugin to 8.9.1 2026-02-09 13:58:03 +01:00
edde746 07c47c308a feat: bundle shared libraries in portable Linux tarball 2026-02-09 13:27:50 +01:00
edde746 8aa7d15dca chore: upgrade dependencies and fix new lint warnings 2026-02-09 09:06:31 +01:00
edde746 839c274e0d fix: resume interrupted downloads after force-kill 2026-02-09 09:04:44 +01:00
edde746 1fb32f1618 fix: debounce alpha jump bar keyboard navigation 2026-02-09 06:38:17 +01:00
edde746 7ec019b12e fix: hide playback controls faster on desktop
close #391
2026-02-09 06:19:33 +01:00
edde746 d313ccbc84 fix: per-arch linux packages 2026-02-08 19:13:45 +01:00
edde746 ce017da78b fix: bundle SDL3 for linux 2026-02-08 18:47:12 +01:00
edde746 7ffd0e53ce feat: linux arm support 2026-02-08 16:39:56 +01:00
edde746 3459c9f59d chore: format 2026-02-08 16:03:40 +01:00
edde746 a5a72147c7 feat: show ratings
close #410
2026-02-08 16:03:23 +01:00
edde746 8f3b924002 docs: update readme 2026-02-08 12:50:20 +01:00
edde746 e915df0490 fix: hero not being focused 2026-02-08 12:38:50 +01:00
edde746 7f0666afbc feat: require profile selection on app open
close #417
2026-02-08 12:07:51 +01:00
edde746 e6fef26e8e fix: suppress stray back KeyUp globally via NavigatorObserver 2026-02-08 11:57:19 +01:00
edde746 2a1c99ac06 fix: dialog autofocus and button sizing 2026-02-08 10:30:14 +01:00
edde746 038ec52e00 fix: add confirm dialog to download delete buttons 2026-02-08 10:04:23 +01:00
edde746 93e83adbc8 fix: cancel auto-skip timer on user interaction
close #398
2026-02-08 08:55:56 +01:00
edde746 7660178b2e feat: download recovery 2026-02-08 08:06:41 +01:00
edde746 fab73a0bc0 fix: profile switcher screen focus
close #415
2026-02-08 08:01:28 +01:00
edde746 0c44a35eb8 feat: log raw API connections 2026-02-08 03:54:22 +01:00
edde746 bc14f20ee6 Merge branch 'feature/thumbnail-previews' 2026-02-07 20:57:39 +01:00
edde746 05abf40c59 fix: thumbnail preview probe improvements 2026-02-07 20:57:12 +01:00
Micah Morrison d76f1ed562 Add support for video thumbnail previews 2026-02-07 14:14:19 -05:00
edde746 747fee0889 feat: log uploading 2026-02-07 20:09:30 +01:00
edde746 101a55552e feat: woa support 2026-02-07 10:46:14 +01:00
github-actions[bot] 358824fcbb chore: update cask to 1.16.1 2026-02-06 21:00:33 +00:00
440 changed files with 69600 additions and 16459 deletions
+19
View File
@@ -0,0 +1,19 @@
.git
build/
.dart_tool/
.idea/
*.tar.gz
nul
libmpv-prefix/
steamfiles/
pubspec_overrides.yaml
# Flutter ephemeral / generated plugin symlinks
linux/flutter/ephemeral/
windows/flutter/
macos/Flutter/
ios/Flutter/
android/.gradle/
android/app/build/
.flutter-plugins
.flutter-plugins-dependencies
+3
View File
@@ -0,0 +1,3 @@
*.sh text eol=lf
*.Dockerfile text eol=lf
Dockerfile text eol=lf
+423 -53
View File
@@ -3,6 +3,10 @@ name: Build
on:
workflow_dispatch:
env:
SENTRY_DART_DEFINE: ${{ github.repository == 'edde746/plezy' && '--dart-define=ENABLE_SENTRY=true' || '' }}
GIT_COMMIT_DART_DEFINE: --dart-define=GIT_COMMIT=${{ github.sha }}
jobs:
build-android:
runs-on: ubuntu-latest
@@ -58,7 +62,7 @@ jobs:
EOF
- name: Build APKs
run: flutter build apk --release --split-per-abi --dart-define=ENABLE_UPDATE_CHECK=true
run: flutter build apk --release --split-per-abi --dart-define=ENABLE_UPDATE_CHECK=true ${{ env.SENTRY_DART_DEFINE }} ${{ env.GIT_COMMIT_DART_DEFINE }}
- name: Clean up keystore
if: always()
@@ -126,7 +130,7 @@ jobs:
run: flutter pub get
- name: Build iOS (no codesign)
run: flutter build ios --release --no-codesign --dart-define=ENABLE_UPDATE_CHECK=true
run: flutter build ios --release --no-codesign --dart-define=ENABLE_UPDATE_CHECK=true ${{ env.SENTRY_DART_DEFINE }} ${{ env.GIT_COMMIT_DART_DEFINE }}
- name: Create IPA
run: |
@@ -184,7 +188,7 @@ jobs:
run: flutter pub get
- name: Build macOS
run: flutter build macos --release --dart-define=ENABLE_UPDATE_CHECK=true
run: flutter build macos --release --dart-define=ENABLE_UPDATE_CHECK=true ${{ env.SENTRY_DART_DEFINE }} ${{ env.GIT_COMMIT_DART_DEFINE }}
- name: Import Code Signing Certificate
env:
@@ -217,11 +221,19 @@ jobs:
APP_PATH="build/macos/Build/Products/Release/Plezy.app"
# Sign all frameworks and dylibs first (inside-out signing)
find "$APP_PATH/Contents/Frameworks" -name "*.framework" -o -name "*.dylib" | while read framework; do
echo "Signing: $framework"
codesign --force --sign "$IDENTITY" --timestamp --options runtime "$framework"
done
# Deep sign everything inside-out: executables, dylibs, XPC services, app bundles, frameworks
find "$APP_PATH/Contents/Frameworks" \( -name "*.xpc" -o -name "*.app" -o -name "*.framework" -o -name "*.dylib" \) -print0 \
| sort -zr \
| while IFS= read -r -d '' item; do
echo "Signing: $item"
codesign --force --sign "$IDENTITY" --timestamp --options runtime "$item"
done
# Sign any remaining bare executables (e.g. Sparkle's Autoupdate)
find "$APP_PATH/Contents/Frameworks" -type f -perm +111 ! -name "*.dylib" ! -path "*/Headers/*" ! -path "*/Modules/*" -print0 \
| while IFS= read -r -d '' exe; do
codesign --force --sign "$IDENTITY" --timestamp --options runtime "$exe" 2>/dev/null || true
done
# Sign the app bundle itself
echo "Signing app bundle: $APP_PATH"
@@ -269,22 +281,41 @@ jobs:
ln -s /Applications dmg-staging/Applications
hdiutil create -format ULMO -srcfolder dmg-staging -volname "Plezy" plezy-macos.dmg
- name: Sign DMG for Sparkle (EdDSA)
if: env.SPARKLE_PRIVATE_KEY != ''
env:
SPARKLE_PRIVATE_KEY: ${{ secrets.SPARKLE_PRIVATE_KEY }}
run: |
printf -- "-----BEGIN ED25519 PRIVATE KEY-----\n%s\n-----END ED25519 PRIVATE KEY-----\n" "$SPARKLE_PRIVATE_KEY" > ed25519_key.pem
OUTPUT=$(dart run auto_updater:sign_update plezy-macos.dmg ed25519_key.pem)
rm ed25519_key.pem
# Extract edSignature value from output like: sparkle:edSignature="..." length="..."
SIGNATURE=$(echo "$OUTPUT" | grep -o 'edSignature="[^"]*"' | sed 's/edSignature="//;s/"//')
echo "MACOS_ED_SIGNATURE=$SIGNATURE" >> $GITHUB_ENV
echo "MACOS_DMG_SIZE=$(stat -f%z plezy-macos.dmg)" >> $GITHUB_ENV
- name: Attest macOS DMG
uses: actions/attest-build-provenance@v2
with:
subject-path: plezy-macos.dmg
- name: Write macOS signature metadata
run: |
echo "${{ env.MACOS_ED_SIGNATURE }}" > macos-ed-signature.txt
echo "${{ env.MACOS_DMG_SIZE }}" > macos-dmg-size.txt
- name: Upload macOS DMG
uses: actions/upload-artifact@v4
with:
name: macos-dmg
path: plezy-macos.dmg
path: |
plezy-macos.dmg
macos-ed-signature.txt
macos-dmg-size.txt
build-windows:
build-windows-x64:
runs-on: windows-latest
permissions:
id-token: write
attestations: write
contents: read
steps:
- uses: actions/checkout@v4
@@ -307,32 +338,136 @@ jobs:
- name: Install dependencies
run: flutter pub get
- name: Build Windows
run: flutter build windows --release --dart-define=ENABLE_UPDATE_CHECK=true
- name: Build Windows x64
run: flutter build windows --release --dart-define=ENABLE_UPDATE_CHECK=true ${{ env.SENTRY_DART_DEFINE }} ${{ env.GIT_COMMIT_DART_DEFINE }}
- name: Build Windows Installer
run: .\windows\build-installer.ps1
- name: Upload x64 build
uses: actions/upload-artifact@v4
with:
name: windows-x64-build
path: build/windows/x64/runner/Release/
build-windows-arm64:
runs-on: windows-11-arm
permissions:
contents: read
steps:
- uses: actions/checkout@v4
- name: Install 7-Zip
run: choco install 7zip -y
- name: Setup Flutter
uses: subosito/flutter-action@v2
with:
channel: "master"
cache: true
- name: Cache Pub dependencies
uses: actions/cache@v4
with:
path: |
~\AppData\Local\Pub\Cache
key: ${{ runner.os }}-arm64-pub-${{ hashFiles('**/pubspec.lock') }}
restore-keys: |
${{ runner.os }}-arm64-pub-
- name: Install dependencies
run: flutter pub get
- name: Build Windows arm64
run: flutter build windows --release --dart-define=ENABLE_UPDATE_CHECK=true ${{ env.SENTRY_DART_DEFINE }} ${{ env.GIT_COMMIT_DART_DEFINE }}
- name: Upload arm64 build
uses: actions/upload-artifact@v4
with:
name: windows-arm64-build
path: build/windows/arm64/runner/Release/
package-windows:
needs: [build-windows-x64, build-windows-arm64]
runs-on: windows-latest
permissions:
id-token: write
attestations: write
contents: read
steps:
- uses: actions/checkout@v4
- name: Setup Dart
uses: dart-lang/setup-dart@v1
- name: Download x64 build
uses: actions/download-artifact@v4
with:
name: windows-x64-build
path: build-x64
- name: Download arm64 build
uses: actions/download-artifact@v4
with:
name: windows-arm64-build
path: build-arm64
- name: Read version from pubspec
id: version
shell: pwsh
run: |
$v = (Select-String -Path pubspec.yaml -Pattern '^version:\s*(\S+)').Matches[0].Groups[1].Value -replace '\+.*'
echo "version=$v" >> $env:GITHUB_OUTPUT
- name: Build installer and portables
run: .\windows\build-installer.ps1 -X64BuildDir "build-x64" -Arm64BuildDir "build-arm64" -Version "${{ steps.version.outputs.version }}"
- name: Sign installer for WinSparkle (EdDSA)
if: env.SPARKLE_PRIVATE_KEY != ''
env:
SPARKLE_PRIVATE_KEY: ${{ secrets.SPARKLE_PRIVATE_KEY }}
shell: pwsh
run: |
mkdir _signer | Out-Null
@{name="signer"; environment=@{sdk=">=3.0.0 <4.0.0"}; dependencies=@{cryptography="^2.7.0"}} | ConvertTo-Json -Depth 3 | Out-File _signer/pubspec.yaml
Invoke-WebRequest -Uri "https://raw.githubusercontent.com/edde746/auto_updater/main/packages/auto_updater/bin/sign_update.dart" -OutFile _signer/sign.dart
Push-Location _signer
dart pub get
Set-Content -Path ed25519_key.pem -Value $env:SPARKLE_PRIVATE_KEY -Encoding ascii -NoNewline
$output = dart run sign.dart ../plezy-windows-installer.exe ed25519_key.pem
Pop-Location
Remove-Item _signer -Recurse -Force
$sig = [regex]::Match($output, 'edSignature="([^"]*)"').Groups[1].Value
Set-Content -Path win-ed-signature.txt -Value $sig -Encoding ascii -NoNewline
Set-Content -Path win-installer-size.txt -Value (Get-Item plezy-windows-installer.exe).Length.ToString() -Encoding ascii -NoNewline
- name: Attest Windows artifacts
uses: actions/attest-build-provenance@v2
with:
subject-path: |
plezy-windows-portable.7z
plezy-windows-x64-portable.7z
plezy-windows-arm64-portable.7z
plezy-windows-installer.exe
- name: Upload Portable Archive
- name: Upload x64 portable
uses: actions/upload-artifact@v4
with:
name: windows-portable
path: plezy-windows-portable.7z
name: windows-x64-portable
path: plezy-windows-x64-portable.7z
- name: Upload Installer
- name: Upload arm64 portable
uses: actions/upload-artifact@v4
with:
name: windows-arm64-portable
path: plezy-windows-arm64-portable.7z
- name: Upload installer
uses: actions/upload-artifact@v4
with:
name: windows-installer
path: plezy-windows-installer.exe
path: |
plezy-windows-installer.exe
win-ed-signature.txt
win-installer-size.txt
build-linux:
build-linux-x64:
runs-on: ubuntu-latest
permissions:
id-token: write
@@ -359,13 +494,24 @@ jobs:
- name: Cache APT packages
uses: awalsh128/cache-apt-pkgs-action@latest
with:
packages: clang cmake ninja-build pkg-config libgtk-3-dev liblzma-dev libstdc++-12-dev libasound2-dev libmpv-dev mpv ruby ruby-dev rubygems build-essential rpm libarchive-tools imagemagick
packages: clang cmake meson ninja-build pkg-config nasm libgtk-3-dev libevdev-dev liblzma-dev libstdc++-12-dev libasound2-dev libass-dev libfreetype-dev libfontconfig-dev libfribidi-dev libharfbuzz-dev libepoxy-dev libegl-dev libgl-dev libgnutls28-dev libpipewire-0.3-dev libva-dev libvdpau-dev libx11-dev libxext-dev libxrandr-dev libxcursor-dev libxi-dev libxss-dev libxpresent-dev libxkbcommon-dev libpulse-dev libdbus-1-dev libdrm-dev libgbm-dev libwayland-dev wayland-protocols liblcms2-dev ruby ruby-dev rubygems build-essential rpm libarchive-tools imagemagick libcurl4-openssl-dev
version: 1.1
- name: Install Linux dependencies
run: |
sudo apt-get update
sudo apt-get install -y clang cmake ninja-build pkg-config libgtk-3-dev liblzma-dev libstdc++-12-dev libasound2-dev libmpv-dev mpv ruby ruby-dev rubygems build-essential rpm libarchive-tools imagemagick
sudo apt-get install -y clang cmake meson ninja-build pkg-config nasm libgtk-3-dev libevdev-dev liblzma-dev libstdc++-12-dev libasound2-dev libass-dev libfreetype-dev libfontconfig-dev libfribidi-dev libharfbuzz-dev libepoxy-dev libegl-dev libgl-dev libgnutls28-dev libpipewire-0.3-dev libva-dev libvdpau-dev libx11-dev libxext-dev libxrandr-dev libxcursor-dev libxi-dev libxss-dev libxpresent-dev libxkbcommon-dev libpulse-dev libdbus-1-dev libdrm-dev libgbm-dev libwayland-dev wayland-protocols liblcms2-dev ruby ruby-dev rubygems build-essential rpm libarchive-tools imagemagick libcurl4-openssl-dev
- name: Cache libmpv build
id: libmpv-cache
uses: actions/cache@v4
with:
path: libmpv-prefix
key: libmpv-${{ runner.arch }}-${{ hashFiles('linux/packaging/build-libmpv.sh') }}
- name: Build libmpv
if: steps.libmpv-cache.outputs.cache-hit != 'true'
run: bash linux/packaging/build-libmpv.sh
- name: Install fpm
run: sudo gem install fpm
@@ -373,47 +519,191 @@ jobs:
- name: Install dependencies
run: flutter pub get
- name: Build Linux
run: flutter build linux --release --dart-define=ENABLE_UPDATE_CHECK=true
- name: Create Archive
run: |
cd build/linux/x64/release/bundle
tar -czf $GITHUB_WORKSPACE/plezy-linux.tar.gz *
- name: Build Linux x64
run: flutter build linux --release --dart-define=ENABLE_UPDATE_CHECK=true ${{ env.SENTRY_DART_DEFINE }} ${{ env.GIT_COMMIT_DART_DEFINE }}
env:
PKG_CONFIG_PATH: ${{ github.workspace }}/libmpv-prefix/lib/pkgconfig:${{ github.workspace }}/libmpv-prefix/lib/x86_64-linux-gnu/pkgconfig
- name: Build Linux Packages
run: OUTPUT_DIR=$GITHUB_WORKSPACE python3 linux/packaging/build-packages.py
run: ARCH_SUFFIX=x64 OUTPUT_DIR=$GITHUB_WORKSPACE python3 linux/packaging/build-packages.py
- name: Attest Linux artifacts
- name: Copy libmpv into bundle
run: |
BUNDLE_LIB=build/linux/x64/release/bundle/lib
LIBMPV_DIR=$(dirname "$(find libmpv-prefix -name 'libmpv.so' | head -1)")
cp -a "$LIBMPV_DIR"/libmpv.so* "$BUNDLE_LIB/"
cp -a libmpv-prefix/lib/libshaderc_shared.so* "$BUNDLE_LIB/"
- name: Bundle shared libraries for portable tarball
run: bash linux/packaging/bundle-libs.sh build/linux/x64/release/bundle
- name: Copy wrapper script into bundle
run: cp linux/packaging/plezy.sh build/linux/x64/release/bundle/plezy.sh
- name: Verify no missing dependencies
run: |
cd build/linux/x64/release/bundle
MISSING=$(LD_LIBRARY_PATH=lib ldd ./plezy 2>&1 | grep "not found" || true)
if [[ -n "$MISSING" ]]; then
echo "ERROR: Unresolved dependencies found:" >&2
echo "$MISSING" >&2
exit 1
fi
echo "All dependencies resolved."
- name: Create tarball
run: |
cd build/linux/x64/release/bundle
tar -czf $GITHUB_WORKSPACE/plezy-linux-x64.tar.gz *
- name: Attest Linux x64 artifacts
uses: actions/attest-build-provenance@v2
with:
subject-path: |
plezy-linux.tar.gz
plezy-linux.deb
plezy-linux.rpm
plezy-linux.pkg.tar.zst
plezy-linux-x64.tar.gz
plezy-linux-x64.deb
plezy-linux-x64.rpm
plezy-linux-x64.pkg.tar.zst
- name: Upload Linux App
- name: Upload Linux x64 artifacts
uses: actions/upload-artifact@v4
with:
name: linux-app
path: plezy-linux.tar.gz
- name: Upload Linux Packages
uses: actions/upload-artifact@v4
with:
name: linux-packages
name: linux-x64
path: |
plezy-linux.deb
plezy-linux.rpm
plezy-linux.pkg.tar.zst
plezy-linux-x64.tar.gz
plezy-linux-x64.deb
plezy-linux-x64.rpm
plezy-linux-x64.pkg.tar.zst
build-linux-arm64:
runs-on: ubuntu-24.04-arm
permissions:
id-token: write
attestations: write
contents: read
steps:
- uses: actions/checkout@v4
- name: Setup Flutter
uses: subosito/flutter-action@v2
with:
channel: "master"
cache: true
- name: Cache Pub dependencies
uses: actions/cache@v4
with:
path: |
~/.pub-cache
key: ${{ runner.os }}-arm64-pub-${{ hashFiles('**/pubspec.lock') }}
restore-keys: |
${{ runner.os }}-arm64-pub-
- name: Cache APT packages
uses: awalsh128/cache-apt-pkgs-action@latest
with:
packages: clang cmake meson ninja-build pkg-config nasm libgtk-3-dev libevdev-dev liblzma-dev libstdc++-12-dev libasound2-dev libass-dev libfreetype-dev libfontconfig-dev libfribidi-dev libharfbuzz-dev libepoxy-dev libegl-dev libgl-dev libgnutls28-dev libpipewire-0.3-dev libva-dev libvdpau-dev libx11-dev libxext-dev libxrandr-dev libxcursor-dev libxi-dev libxss-dev libxpresent-dev libxkbcommon-dev libpulse-dev libdbus-1-dev libdrm-dev libgbm-dev libwayland-dev wayland-protocols liblcms2-dev ruby ruby-dev rubygems build-essential rpm libarchive-tools imagemagick libcurl4-openssl-dev
version: 1.1
- name: Install Linux dependencies
run: |
sudo apt-get update
sudo apt-get install -y clang cmake meson ninja-build pkg-config nasm libgtk-3-dev libevdev-dev liblzma-dev libstdc++-12-dev libasound2-dev libass-dev libfreetype-dev libfontconfig-dev libfribidi-dev libharfbuzz-dev libepoxy-dev libegl-dev libgl-dev libgnutls28-dev libpipewire-0.3-dev libva-dev libvdpau-dev libx11-dev libxext-dev libxrandr-dev libxcursor-dev libxi-dev libxss-dev libxpresent-dev libxkbcommon-dev libpulse-dev libdbus-1-dev libdrm-dev libgbm-dev libwayland-dev wayland-protocols liblcms2-dev ruby ruby-dev rubygems build-essential rpm libarchive-tools imagemagick libcurl4-openssl-dev
- name: Cache libmpv build
id: libmpv-cache
uses: actions/cache@v4
with:
path: libmpv-prefix
key: libmpv-${{ runner.arch }}-${{ hashFiles('linux/packaging/build-libmpv.sh') }}
- name: Build libmpv
if: steps.libmpv-cache.outputs.cache-hit != 'true'
run: bash linux/packaging/build-libmpv.sh
- name: Install fpm
run: sudo gem install fpm
- name: Install dependencies
run: flutter pub get
- name: Build Linux arm64
run: flutter build linux --release --dart-define=ENABLE_UPDATE_CHECK=true ${{ env.SENTRY_DART_DEFINE }} ${{ env.GIT_COMMIT_DART_DEFINE }}
env:
PKG_CONFIG_PATH: ${{ github.workspace }}/libmpv-prefix/lib/pkgconfig:${{ github.workspace }}/libmpv-prefix/lib/aarch64-linux-gnu/pkgconfig
- name: Find bundle directory
id: find-bundle
run: |
BUNDLE_DIR=$(find build/linux -path "*/release/bundle" -type d | head -1)
echo "bundle_dir=$BUNDLE_DIR" >> $GITHUB_OUTPUT
- name: Build Linux Packages
run: |
BUILD_DIR=${{ steps.find-bundle.outputs.bundle_dir }} \
ARCH_SUFFIX=arm64 \
OUTPUT_DIR=$GITHUB_WORKSPACE \
python3 linux/packaging/build-packages.py
- name: Copy libmpv into bundle
run: |
BUNDLE_LIB=${{ steps.find-bundle.outputs.bundle_dir }}/lib
LIBMPV_DIR=$(dirname "$(find libmpv-prefix -name 'libmpv.so' | head -1)")
cp -a "$LIBMPV_DIR"/libmpv.so* "$BUNDLE_LIB/"
cp -a libmpv-prefix/lib/libshaderc_shared.so* "$BUNDLE_LIB/"
- name: Bundle shared libraries for portable tarball
run: bash linux/packaging/bundle-libs.sh ${{ steps.find-bundle.outputs.bundle_dir }}
- name: Copy wrapper script into bundle
run: cp linux/packaging/plezy.sh ${{ steps.find-bundle.outputs.bundle_dir }}/plezy.sh
- name: Verify no missing dependencies
run: |
cd ${{ steps.find-bundle.outputs.bundle_dir }}
MISSING=$(LD_LIBRARY_PATH=lib ldd ./plezy 2>&1 | grep "not found" || true)
if [[ -n "$MISSING" ]]; then
echo "ERROR: Unresolved dependencies found:" >&2
echo "$MISSING" >&2
exit 1
fi
echo "All dependencies resolved."
- name: Create tarball
run: |
cd ${{ steps.find-bundle.outputs.bundle_dir }}
tar -czf $GITHUB_WORKSPACE/plezy-linux-arm64.tar.gz *
- name: Attest Linux arm64 artifacts
uses: actions/attest-build-provenance@v2
with:
subject-path: |
plezy-linux-arm64.tar.gz
plezy-linux-arm64.deb
plezy-linux-arm64.rpm
plezy-linux-arm64.pkg.tar.zst
- name: Upload Linux arm64 artifacts
uses: actions/upload-artifact@v4
with:
name: linux-arm64
path: |
plezy-linux-arm64.tar.gz
plezy-linux-arm64.deb
plezy-linux-arm64.rpm
plezy-linux-arm64.pkg.tar.zst
create-release:
needs: [build-android, build-ios, build-macos, build-windows, build-linux]
needs: [build-android, build-ios, build-macos, package-windows, build-linux-x64, build-linux-arm64]
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v4
with:
sparse-checkout: pubspec.yaml
sparse-checkout-cone-mode: false
- name: Download all artifacts
uses: actions/download-artifact@v4
with:
@@ -422,6 +712,84 @@ jobs:
- name: Display structure of downloaded files
run: ls -R artifacts
- name: Read version from pubspec.yaml
id: version
run: |
VERSION=$(grep '^version:' pubspec.yaml | sed 's/version: //' | sed 's/+.*//')
BUILD_NUMBER=$(grep '^version:' pubspec.yaml | sed 's/.*+//')
echo "version=$VERSION" >> $GITHUB_OUTPUT
echo "build_number=$BUILD_NUMBER" >> $GITHUB_OUTPUT
- name: Generate appcast.xml
run: |
VERSION="${{ steps.version.outputs.version }}"
BUILD_NUMBER="${{ steps.version.outputs.build_number }}"
# Read macOS signature metadata (may be empty if secrets not configured)
MACOS_ED_SIG=""
MACOS_DMG_SIZE="0"
if [ -f artifacts/macos-dmg/macos-ed-signature.txt ]; then
MACOS_ED_SIG=$(cat artifacts/macos-dmg/macos-ed-signature.txt)
fi
if [ -f artifacts/macos-dmg/macos-dmg-size.txt ]; then
MACOS_DMG_SIZE=$(cat artifacts/macos-dmg/macos-dmg-size.txt)
fi
# Read Windows signature metadata (may be empty if secrets not configured)
WIN_ED_SIG=""
WIN_INSTALLER_SIZE="0"
if [ -f artifacts/windows-installer/win-ed-signature.txt ]; then
WIN_ED_SIG=$(cat artifacts/windows-installer/win-ed-signature.txt)
fi
if [ -f artifacts/windows-installer/win-installer-size.txt ]; then
WIN_INSTALLER_SIZE=$(cat artifacts/windows-installer/win-installer-size.txt)
fi
cat > appcast.xml << XMLEOF
<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:sparkle="http://www.andymatuschak.org/xml-namespaces/sparkle">
<channel>
<title>Plezy Updates</title>
<item>
<title>Version ${VERSION}</title>
<sparkle:version>${BUILD_NUMBER}</sparkle:version>
<sparkle:shortVersionString>${VERSION}</sparkle:shortVersionString>
<sparkle:releaseNotesLink>https://gh-html.edde746.dev/edde746/plezy/${VERSION}</sparkle:releaseNotesLink>
XMLEOF
# macOS enclosure
if [ -n "$MACOS_ED_SIG" ]; then
cat >> appcast.xml << XMLEOF
<enclosure url="https://github.com/edde746/plezy/releases/download/${VERSION}/plezy-macos.dmg"
length="${MACOS_DMG_SIZE}" type="application/octet-stream"
sparkle:edSignature="${MACOS_ED_SIG}"
sparkle:os="macos" />
XMLEOF
fi
# Windows enclosure
if [ -n "$WIN_ED_SIG" ]; then
cat >> appcast.xml << XMLEOF
<enclosure url="https://github.com/edde746/plezy/releases/download/${VERSION}/plezy-windows-installer.exe"
length="${WIN_INSTALLER_SIZE}" type="application/octet-stream"
sparkle:edSignature="${WIN_ED_SIG}"
sparkle:installerArguments="/SILENT /SP-"
sparkle:os="windows" />
XMLEOF
fi
cat >> appcast.xml << 'XMLEOF'
</item>
</channel>
</rss>
XMLEOF
# Clean up leading whitespace from heredoc indentation
sed -i 's/^ //' appcast.xml
echo "Generated appcast.xml:"
cat appcast.xml
- name: Create Release
uses: softprops/action-gh-release@v1
with:
@@ -431,10 +799,12 @@ jobs:
artifacts/android-apk/plezy-android-x86_64.tar.gz
artifacts/ios-ipa/plezy-ios.ipa
artifacts/macos-dmg/plezy-macos.dmg
artifacts/windows-portable/plezy-windows-portable.7z
artifacts/windows-x64-portable/plezy-windows-x64-portable.7z
artifacts/windows-arm64-portable/plezy-windows-arm64-portable.7z
artifacts/windows-installer/plezy-windows-installer.exe
artifacts/linux-app/plezy-linux.tar.gz
artifacts/linux-packages/*
artifacts/linux-x64/*
artifacts/linux-arm64/*
appcast.xml
draft: true
prerelease: false
generate_release_notes: true
+27
View File
@@ -0,0 +1,27 @@
name: SonarQube
on:
workflow_dispatch:
jobs:
sonarqube:
name: SonarQube
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Flutter
uses: subosito/flutter-action@v2
with:
channel: "stable"
cache: true
- name: Install dependencies
run: flutter pub get
- name: SonarQube Scan
uses: SonarSource/sonarqube-scan-action@v6
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
@@ -1,4 +1,4 @@
name: Update Homebrew Cask
name: Update Packages
on:
release:
@@ -6,7 +6,7 @@ on:
workflow_dispatch:
jobs:
update-cask:
update-homebrew:
runs-on: macos-latest
permissions:
contents: write
@@ -43,3 +43,12 @@ jobs:
else
echo "No cask changes to commit."
fi
update-winget:
runs-on: windows-latest
steps:
- uses: vedantmgoyal9/winget-releaser@v2
with:
identifier: edde746.Plezy
installers-regex: 'plezy-windows-installer\.exe$'
token: ${{ secrets.WINGET_TOKEN }}
+1
View File
@@ -32,6 +32,7 @@ migrate_working_dir/
.pub-cache/
.pub/
/build/
/debug-info/
# Symbolication related
app.*.symbols
+2 -2
View File
@@ -1,6 +1,6 @@
cask "plezy" do
version "1.16.0"
sha256 "65f4d629dd98e90dace71166a279a5b58334182ca7f60f85a79b3a4e2e2f8a02"
version "1.26.1"
sha256 "1474e1fb13689c08f9a25eb426bc84cc95c1127f85c4fb60ee7cb9ec57eb516a"
url "https://github.com/edde746/plezy/releases/download/#{version}/plezy-macos.dmg"
name "Plezy"
+18 -6
View File
@@ -13,21 +13,27 @@ A modern Plex client for desktop and mobile. Built with Flutter for native perfo
## Download
### Mobile
<a href='https://apps.apple.com/us/app/id6754315964'><img height='60' alt='Download on the App Store' src='./assets/app-store-badge.png'/></a>
<a href='https://play.google.com/store/apps/details?id=com.edde746.plezy'><img height='60' alt='Get it on Google Play' src='./assets/play-store-badge.png'/></a>
<a href='https://www.amazon.com/gp/product/B0GK65CVS1'><img height='60' alt='Available at the Amazon App Store' src='./assets/amazon-badge.png'/></a>
### Desktop
- [Windows (x64)](https://github.com/edde746/plezy/releases/latest/download/plezy-windows-installer.exe)
- [macOS (Universal)](https://github.com/edde746/plezy/releases/latest/download/plezy-macos.dmg)
- [Linux (x64)](https://github.com/edde746/plezy/releases/latest) - .deb, .rpm, .pkg.tar.zst, and portable tar.gz available
- [Windows (x64, arm64)](https://github.com/edde746/plezy/releases/latest/download/plezy-windows-installer.exe)
- [macOS (x64, arm64)](https://github.com/edde746/plezy/releases/latest/download/plezy-macos.dmg)
- [Linux (x64, arm64)](https://github.com/edde746/plezy/releases/latest) - .deb, .rpm, .pkg.tar.zst, and portable tar.gz available
- [NixOS/Nix](https://github.com/mio-19/nurpkgs/tree/main/pkgs/plezy) - Community package by [@mio-19](https://github.com/mio-19)
- **Homebrew** (macOS):
```bash
brew tap edde746/plezy https://github.com/edde746/plezy
brew install --cask plezy
```
- [AUR](https://aur.archlinux.org/packages/plezy-bin) (Arch Linux) - Community maintained by [@jianglai](https://github.com/jianglai):
```bash
yay -S plezy-bin
```
- **WinGet** (Windows):
```bash
winget install edde746.plezy
```
## Features
@@ -43,12 +49,18 @@ A modern Plex client for desktop and mobile. Built with Flutter for native perfo
### 🎬 Playback
- Wide codec support (HEVC, AV1, VP9, and more)
- HDR and Dolby Vision (iOS, macOS, Windows)
- HDR and Dolby Vision (not Linux)
- Full ASS/SSA subtitle support
- Audio and subtitle preferences synced with Plex profile
- Progress sync and resume
- Auto-play next episode
### 📺 Live TV & DVR
- EPG guide grid
- Channel tuning
- DVR recording rules and scheduled recordings
- Multi-server DVR support
### 📥 Downloads
- Download media for offline viewing
- Background downloads with queue management
+55 -1
View File
@@ -8,8 +8,62 @@ analyzer:
- dart_code_linter
dart_code_linter:
extends:
- package:dart_code_linter/presets/recommended.yaml
rules:
- avoid-unused-parameters
# --- Flutter rules (on top of recommended) ---
- avoid-border-all
- avoid-shrink-wrap-in-lists
- avoid-expanded-as-spacer
- avoid-wrapping-in-padding
- prefer-const-border-radius
- prefer-correct-edge-insets-constructor
- prefer-define-hero-tag
- use-setstate-synchronously
# --- Additional useful Dart rules ---
- avoid-cascade-after-if-null
- avoid-collection-methods-with-unrelated-types
- avoid-unnecessary-type-assertions
- avoid-unrelated-type-assertions
- double-literal-format
- prefer-first
- prefer-last
- prefer-enums-by-name
- prefer-commenting-analyzer-ignores
# --- Disable noisy rules from recommended preset ---
- no-magic-number: false
- avoid-dynamic: false
- format-comment: false
- newline-before-return: false
- prefer-moving-to-variable: false
- member-ordering: false
- prefer-extracting-callbacks: false
- avoid-returning-widgets: false
- no-equal-arguments: false
- avoid-passing-async-when-sync-expected: false
- avoid-redundant-async: false
- no-empty-block: false
- prefer-trailing-comma: false
- avoid-non-null-assertion: false
- prefer-conditional-expressions: false
metrics:
cyclomatic-complexity: 70
halstead-volume: 16000
maintainability-index: 8
maximum-nesting-level: 7
number-of-parameters: 25
number-of-methods: 150
source-lines-of-code: 500
anti-patterns:
- long-method:
lines-of-code: 500
- long-parameter-list:
number-of-parameters: 25
formatter:
page_width: 120
+10
View File
@@ -0,0 +1,10 @@
# Autogenerated by fastlane
#
# Ensure this file is checked in to source control!
source "https://rubygems.org"
gem 'fastlane'
plugins_path = File.join(File.dirname(__FILE__), 'fastlane', 'Pluginfile')
eval_gemfile(plugins_path) if File.exist?(plugins_path)
+244
View File
@@ -0,0 +1,244 @@
GEM
remote: https://rubygems.org/
specs:
CFPropertyList (3.0.8)
abbrev (0.1.2)
addressable (2.8.8)
public_suffix (>= 2.0.2, < 8.0)
artifactory (3.0.17)
atomos (0.1.3)
aws-eventstream (1.4.0)
aws-partitions (1.1215.0)
aws-sdk-core (3.242.0)
aws-eventstream (~> 1, >= 1.3.0)
aws-partitions (~> 1, >= 1.992.0)
aws-sigv4 (~> 1.9)
base64
bigdecimal
jmespath (~> 1, >= 1.6.1)
logger
aws-sdk-kms (1.122.0)
aws-sdk-core (~> 3, >= 3.241.4)
aws-sigv4 (~> 1.5)
aws-sdk-s3 (1.213.0)
aws-sdk-core (~> 3, >= 3.241.4)
aws-sdk-kms (~> 1)
aws-sigv4 (~> 1.5)
aws-sigv4 (1.12.1)
aws-eventstream (~> 1, >= 1.0.2)
babosa (1.0.4)
base64 (0.2.0)
benchmark (0.5.0)
bigdecimal (4.0.1)
claide (1.1.0)
colored (1.2)
colored2 (3.1.2)
commander (4.6.0)
highline (~> 2.0.0)
csv (3.3.5)
declarative (0.0.20)
digest-crc (0.7.0)
rake (>= 12.0.0, < 14.0.0)
domain_name (0.6.20240107)
dotenv (2.8.1)
emoji_regex (3.2.3)
excon (0.112.0)
faraday (1.10.5)
faraday-em_http (~> 1.0)
faraday-em_synchrony (~> 1.0)
faraday-excon (~> 1.1)
faraday-httpclient (~> 1.0)
faraday-multipart (~> 1.0)
faraday-net_http (~> 1.0)
faraday-net_http_persistent (~> 1.0)
faraday-patron (~> 1.0)
faraday-rack (~> 1.0)
faraday-retry (~> 1.0)
ruby2_keywords (>= 0.0.4)
faraday-cookie_jar (0.0.8)
faraday (>= 0.8.0)
http-cookie (>= 1.0.0)
faraday-em_http (1.0.0)
faraday-em_synchrony (1.0.1)
faraday-excon (1.1.0)
faraday-httpclient (1.0.1)
faraday-multipart (1.2.0)
multipart-post (~> 2.0)
faraday-net_http (1.0.2)
faraday-net_http_persistent (1.2.0)
faraday-patron (1.0.0)
faraday-rack (1.0.0)
faraday-retry (1.0.3)
faraday_middleware (1.2.1)
faraday (~> 1.0)
fastimage (2.4.0)
fastlane (2.232.1)
CFPropertyList (>= 2.3, < 4.0.0)
abbrev (~> 0.1.2)
addressable (>= 2.8, < 3.0.0)
artifactory (~> 3.0)
aws-sdk-s3 (~> 1.197)
babosa (>= 1.0.3, < 2.0.0)
base64 (~> 0.2.0)
benchmark (>= 0.1.0)
bundler (>= 1.17.3, < 5.0.0)
colored (~> 1.2)
commander (~> 4.6)
csv (~> 3.3)
dotenv (>= 2.1.1, < 3.0.0)
emoji_regex (>= 0.1, < 4.0)
excon (>= 0.71.0, < 1.0.0)
faraday (~> 1.0)
faraday-cookie_jar (~> 0.0.6)
faraday_middleware (~> 1.0)
fastimage (>= 2.1.0, < 3.0.0)
fastlane-sirp (>= 1.0.0)
gh_inspector (>= 1.1.2, < 2.0.0)
google-apis-androidpublisher_v3 (~> 0.3)
google-apis-playcustomapp_v1 (~> 0.1)
google-cloud-env (>= 1.6.0, <= 2.1.1)
google-cloud-storage (~> 1.31)
highline (~> 2.0)
http-cookie (~> 1.0.5)
json (< 3.0.0)
jwt (>= 2.1.0, < 3)
logger (>= 1.6, < 2.0)
mini_magick (>= 4.9.4, < 5.0.0)
multipart-post (>= 2.0.0, < 3.0.0)
mutex_m (~> 0.3.0)
naturally (~> 2.2)
nkf (~> 0.2.0)
optparse (>= 0.1.1, < 1.0.0)
ostruct (>= 0.1.0)
plist (>= 3.1.0, < 4.0.0)
rubyzip (>= 2.0.0, < 3.0.0)
security (= 0.1.5)
simctl (~> 1.6.3)
terminal-notifier (>= 2.0.0, < 3.0.0)
terminal-table (~> 3)
tty-screen (>= 0.6.3, < 1.0.0)
tty-spinner (>= 0.8.0, < 1.0.0)
word_wrap (~> 1.0.0)
xcodeproj (>= 1.13.0, < 2.0.0)
xcpretty (~> 0.4.1)
xcpretty-travis-formatter (>= 0.0.3, < 2.0.0)
fastlane-plugin-amazon_appstore (1.4.0)
faraday (~> 1.0)
faraday_middleware (~> 1.0)
fastlane-sirp (1.0.0)
sysrandom (~> 1.0)
gh_inspector (1.1.3)
google-apis-androidpublisher_v3 (0.96.0)
google-apis-core (>= 0.15.0, < 2.a)
google-apis-core (0.18.0)
addressable (~> 2.5, >= 2.5.1)
googleauth (~> 1.9)
httpclient (>= 2.8.3, < 3.a)
mini_mime (~> 1.0)
mutex_m
representable (~> 3.0)
retriable (>= 2.0, < 4.a)
google-apis-iamcredentials_v1 (0.26.0)
google-apis-core (>= 0.15.0, < 2.a)
google-apis-playcustomapp_v1 (0.17.0)
google-apis-core (>= 0.15.0, < 2.a)
google-apis-storage_v1 (0.60.0)
google-apis-core (>= 0.15.0, < 2.a)
google-cloud-core (1.8.0)
google-cloud-env (>= 1.0, < 3.a)
google-cloud-errors (~> 1.0)
google-cloud-env (2.1.1)
faraday (>= 1.0, < 3.a)
google-cloud-errors (1.5.0)
google-cloud-storage (1.58.0)
addressable (~> 2.8)
digest-crc (~> 0.4)
google-apis-core (>= 0.18, < 2)
google-apis-iamcredentials_v1 (~> 0.18)
google-apis-storage_v1 (>= 0.42)
google-cloud-core (~> 1.6)
googleauth (~> 1.9)
mini_mime (~> 1.0)
googleauth (1.11.2)
faraday (>= 1.0, < 3.a)
google-cloud-env (~> 2.1)
jwt (>= 1.4, < 3.0)
multi_json (~> 1.11)
os (>= 0.9, < 2.0)
signet (>= 0.16, < 2.a)
highline (2.0.3)
http-cookie (1.0.8)
domain_name (~> 0.5)
httpclient (2.9.0)
mutex_m
jmespath (1.6.2)
json (2.18.1)
jwt (2.10.2)
base64
logger (1.7.0)
mini_magick (4.13.2)
mini_mime (1.1.5)
multi_json (1.19.1)
multipart-post (2.4.1)
mutex_m (0.3.0)
nanaimo (0.4.0)
naturally (2.3.0)
nkf (0.2.0)
optparse (0.8.1)
os (1.1.4)
ostruct (0.6.3)
plist (3.7.2)
public_suffix (7.0.2)
rake (13.3.1)
representable (3.2.0)
declarative (< 0.1.0)
trailblazer-option (>= 0.1.1, < 0.2.0)
uber (< 0.2.0)
retriable (3.1.2)
rexml (3.4.4)
rouge (3.28.0)
ruby2_keywords (0.0.5)
rubyzip (2.4.1)
security (0.1.5)
signet (0.21.0)
addressable (~> 2.8)
faraday (>= 0.17.5, < 3.a)
jwt (>= 1.5, < 4.0)
multi_json (~> 1.10)
simctl (1.6.10)
CFPropertyList
naturally
sysrandom (1.0.5)
terminal-notifier (2.0.0)
terminal-table (3.0.2)
unicode-display_width (>= 1.1.1, < 3)
trailblazer-option (0.1.2)
tty-cursor (0.7.1)
tty-screen (0.8.2)
tty-spinner (0.9.3)
tty-cursor (~> 0.7)
uber (0.1.0)
unicode-display_width (2.6.0)
word_wrap (1.0.0)
xcodeproj (1.27.0)
CFPropertyList (>= 2.3.3, < 4.0)
atomos (~> 0.1.3)
claide (>= 1.0.2, < 2.0)
colored2 (~> 3.1)
nanaimo (~> 0.4.0)
rexml (>= 3.3.6, < 4.0)
xcpretty (0.4.1)
rouge (~> 3.28.0)
xcpretty-travis-formatter (1.0.1)
xcpretty (~> 0.2, >= 0.0.7)
PLATFORMS
arm64-darwin-25
ruby
DEPENDENCIES
fastlane
fastlane-plugin-amazon_appstore
BUNDLED WITH
2.7.2
+67 -7
View File
@@ -8,6 +8,33 @@ plugins {
id("dev.flutter.flutter-gradle-plugin")
}
val doviVersion = "2.3.1"
val doviDir = layout.buildDirectory.dir("libdovi").get().asFile
val doviAbis = mapOf(
"arm64-v8a" to "aarch64-linux-android",
"armeabi-v7a" to "armv7-linux-androideabi",
"x86" to "i686-linux-android",
"x86_64" to "x86_64-linux-android",
)
val downloadLibdovi by tasks.registering {
val stamp = File(doviDir, ".version")
outputs.upToDateWhen { stamp.exists() && stamp.readText().trim() == doviVersion }
doLast {
doviDir.mkdirs()
val baseUrl = "https://github.com/edde746/libdovi-builds/releases/download/v$doviVersion"
doviAbis.forEach { (abi, triple) ->
val archive = File(doviDir, "$triple.tar.gz")
exec { commandLine("curl", "-sfL", "$baseUrl/libdovi-$triple.tar.gz", "-o", archive.absolutePath) }
val outDir = File(doviDir, "$abi/lib")
outDir.mkdirs()
exec { commandLine("tar", "-xzf", archive.absolutePath, "-C", outDir.absolutePath) }
archive.delete()
}
stamp.writeText(doviVersion)
}
}
android {
namespace = "com.edde746.plezy"
compileSdk = flutter.compileSdkVersion
@@ -26,10 +53,32 @@ android {
applicationId = "com.edde746.plezy"
// You can update the following values to match your application needs.
// For more information, see: https://flutter.dev/to/review-gradle-config.
minSdk = 26 // Required by libmpv-android
minSdk = 25 // Fire OS 6.x (API 25); overrides libmpv-android's minSdk=26
targetSdk = flutter.targetSdkVersion
versionCode = flutter.versionCode
versionName = flutter.versionName
externalNativeBuild {
cmake {
arguments += listOf(
"-DDOVI_ENABLE_LIBDOVI=ON",
"-DDOVI_LIBDOVI_PREBUILT_ROOT=${doviDir.absolutePath}"
)
}
}
if (System.getenv("AMAZON") != null) {
versionCode = (flutter.versionCode ?: 0) + 3000
ndk {
abiFilters += listOf("armeabi-v7a", "arm64-v8a")
}
}
}
externalNativeBuild {
cmake {
path = file("src/main/cpp/CMakeLists.txt")
}
}
signingConfigs {
@@ -55,6 +104,9 @@ android {
signingConfig = signingConfigs.getByName("release")
}
// If key.properties doesn't exist, it will use debug signing for CI builds
ndk {
debugSymbolLevel = "FULL"
}
}
}
@@ -70,6 +122,11 @@ flutter {
source = "../.."
}
// Download libdovi before any CMake/native build task
tasks.matching { it.name.contains("CMake") || it.name.contains("externalNative") }.configureEach {
dependsOn(downloadLibdovi)
}
dependencies {
implementation("dev.jdtech.mpv:libmpv:0.5.1")
@@ -77,16 +134,19 @@ dependencies {
implementation("androidx.tvprovider:tvprovider:1.0.0")
// Media3 ExoPlayer for Android
implementation("androidx.media3:media3-exoplayer:1.5.1")
implementation("androidx.media3:media3-ui:1.5.1")
implementation("androidx.media3:media3-common:1.5.1")
implementation("androidx.media3:media3-session:1.5.1")
implementation("androidx.media3:media3-exoplayer:1.9.2")
implementation("androidx.media3:media3-ui:1.9.2")
implementation("androidx.media3:media3-common:1.9.2")
// OkHttp for connection pooling (prevents TCP reconnect stutter at high bitrates)
implementation("com.squareup.okhttp3:okhttp:4.12.0")
implementation("androidx.media3:media3-datasource-okhttp:1.9.2")
// FFmpeg audio decoder for unsupported codecs (ALAC, DTS, TrueHD, etc.)
implementation("org.jellyfin.media3:media3-ffmpeg-decoder:1.9.0+1")
// libass-android for ASS/SSA subtitle rendering
implementation("io.github.peerless2012:ass-media:0.4.0-beta01")
implementation("io.github.peerless2012:ass-media:0.4.0")
// ass-kt core library (needed for AssRender.setFontScale)
implementation("io.github.peerless2012:ass-kt:0.4.0-beta01")
implementation("io.github.peerless2012:ass-kt:0.4.0")
}
+26 -4
View File
@@ -1,15 +1,21 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools">
<!-- Allow minSdk=25 despite libmpv-android declaring minSdk=26 -->
<uses-sdk tools:overrideLibrary="dev.jdtech.mpv" />
<!-- Internet access permissions -->
<uses-permission android:name="android.permission.INTERNET"/>
<!-- PIP Permissions -->
<!-- Camera permission for QR code scanning (companion remote pairing) -->
<uses-permission android:name="android.permission.CAMERA"/>
<!-- PIP and media session foreground service permissions -->
<uses-permission android:name="android.permission.FOREGROUND_SERVICE"/>
<uses-permission android:name="android.permission.FOREGROUND_SERVICE_MEDIA_PLAYBACK"/>
<!-- Media session permissions for OS media controls -->
<uses-permission android:name="android.permission.FOREGROUND_SERVICE"/>
<uses-permission android:name="android.permission.FOREGROUND_SERVICE_MEDIA_PLAYBACK"/>
<!-- Background download notifications and foreground service -->
<uses-permission android:name="android.permission.POST_NOTIFICATIONS"/>
<uses-permission android:name="android.permission.FOREGROUND_SERVICE_DATA_SYNC"/>
<!-- Explicitly remove media permissions that media_kit may add -->
<uses-permission android:name="android.permission.READ_MEDIA_AUDIO" tools:node="remove" />
@@ -33,6 +39,7 @@
android:icon="@mipmap/ic_launcher"
android:banner="@drawable/tv_banner"
android:appCategory="video"
android:largeHeap="true"
android:usesCleartextTraffic="true">
<activity
android:name=".MainActivity"
@@ -66,6 +73,16 @@
<data android:scheme="plezy" android:host="play"/>
</intent-filter>
</activity>
<!-- FileProvider for sharing downloaded files with external players -->
<provider
android:name="androidx.core.content.FileProvider"
android:authorities="com.edde746.plezy.fileprovider"
android:exported="false"
android:grantUriPermissions="true">
<meta-data
android:name="android.support.FILE_PROVIDER_PATHS"
android:resource="@xml/file_provider_paths" />
</provider>
<!-- Don't delete the meta-data below.
This is used by the Flutter tool to generate GeneratedPluginRegistrant.java -->
<meta-data
@@ -91,5 +108,10 @@
<action android:name="android.intent.action.VIEW" />
<data android:scheme="http" />
</intent>
<!-- Required to resolve external video player apps on Android 11+ -->
<intent>
<action android:name="android.intent.action.VIEW" />
<data android:mimeType="video/*" />
</intent>
</queries>
</manifest>
+19
View File
@@ -0,0 +1,19 @@
cmake_minimum_required(VERSION 3.22.1)
project(dovi_bridge)
option(DOVI_ENABLE_LIBDOVI "Link real libdovi" ON)
set(DOVI_LIBDOVI_PREBUILT_ROOT "" CACHE PATH "Path to prebuilt libdovi")
add_library(dovi_bridge SHARED dovi_bridge.cpp)
if(DOVI_ENABLE_LIBDOVI)
add_library(dovi_static STATIC IMPORTED)
set_target_properties(dovi_static PROPERTIES
IMPORTED_LOCATION "${DOVI_LIBDOVI_PREBUILT_ROOT}/${ANDROID_ABI}/lib/libdovi.a")
target_compile_definitions(dovi_bridge PRIVATE DOVI_REAL_LINKED=1)
target_include_directories(dovi_bridge PRIVATE ${CMAKE_SOURCE_DIR}/include)
target_link_libraries(dovi_bridge dovi_static log)
else()
target_compile_definitions(dovi_bridge PRIVATE DOVI_REAL_LINKED=0)
target_link_libraries(dovi_bridge log)
endif()
+105
View File
@@ -0,0 +1,105 @@
#include <jni.h>
#include <android/log.h>
#include <cstring>
#define TAG "DoviBridge"
#define LOGI(...) __android_log_print(ANDROID_LOG_INFO, TAG, __VA_ARGS__)
#define LOGW(...) __android_log_print(ANDROID_LOG_WARN, TAG, __VA_ARGS__)
#if DOVI_REAL_LINKED
#include "include/libdovi/rpu_parser.h"
#endif
static const char* BRIDGE_VERSION = "1.0.0";
extern "C" JNIEXPORT jbyteArray JNICALL
Java_com_edde746_plezy_exoplayer_DoviBridge_nativeConvertDv7RpuToDv81(
JNIEnv *env, jclass, jbyteArray payload, jint mode) {
#if !DOVI_REAL_LINKED
return nullptr;
#else
if (payload == nullptr) return nullptr;
jsize len = env->GetArrayLength(payload);
if (len <= 0) return nullptr;
jbyte *buf = env->GetByteArrayElements(payload, nullptr);
if (buf == nullptr) return nullptr;
// Try dovi_parse_unspec62_nalu first (handles escaped NALs), fallback to dovi_parse_rpu
DoviRpuOpaque *rpu = dovi_parse_unspec62_nalu(
reinterpret_cast<const uint8_t *>(buf), static_cast<size_t>(len));
if (rpu == nullptr) {
env->ReleaseByteArrayElements(payload, buf, JNI_ABORT);
return nullptr;
}
const char *err = dovi_rpu_get_error(rpu);
if (err != nullptr) {
// Fallback: try dovi_parse_rpu (raw RPU without NAL framing)
dovi_rpu_free(rpu);
rpu = dovi_parse_rpu(
reinterpret_cast<const uint8_t *>(buf), static_cast<size_t>(len));
if (rpu == nullptr) {
env->ReleaseByteArrayElements(payload, buf, JNI_ABORT);
return nullptr;
}
err = dovi_rpu_get_error(rpu);
if (err != nullptr) {
LOGW("RPU parse failed: %s", err);
dovi_rpu_free(rpu);
env->ReleaseByteArrayElements(payload, buf, JNI_ABORT);
return nullptr;
}
}
env->ReleaseByteArrayElements(payload, buf, JNI_ABORT);
// Convert to target profile (mode 2 = P8.1 with no-op curves)
int32_t ret = dovi_convert_rpu_with_mode(rpu, static_cast<uint8_t>(mode));
if (ret != 0) {
err = dovi_rpu_get_error(rpu);
LOGW("RPU conversion failed (mode %d): %s", mode, err ? err : "unknown");
dovi_rpu_free(rpu);
return nullptr;
}
// Write back as UNSPEC62 NAL
const DoviData *out = dovi_write_unspec62_nalu(rpu);
if (out == nullptr || out->data == nullptr || out->len == 0) {
err = dovi_rpu_get_error(rpu);
LOGW("RPU write failed: %s", err ? err : "unknown");
if (out != nullptr) dovi_data_free(out);
dovi_rpu_free(rpu);
return nullptr;
}
jbyteArray result = env->NewByteArray(static_cast<jsize>(out->len));
if (result != nullptr) {
env->SetByteArrayRegion(result, 0, static_cast<jsize>(out->len),
reinterpret_cast<const jbyte *>(out->data));
}
dovi_data_free(out);
dovi_rpu_free(rpu);
return result;
#endif
}
extern "C" JNIEXPORT jboolean JNICALL
Java_com_edde746_plezy_exoplayer_DoviBridge_nativeIsConversionPathReady(
JNIEnv *, jclass) {
#if DOVI_REAL_LINKED
return JNI_TRUE;
#else
return JNI_FALSE;
#endif
}
extern "C" JNIEXPORT jstring JNICALL
Java_com_edde746_plezy_exoplayer_DoviBridge_nativeGetBridgeVersion(
JNIEnv *env, jclass) {
return env->NewStringUTF(BRIDGE_VERSION);
}
@@ -0,0 +1,747 @@
// SPDX-License-Identifier: MIT
#ifndef DOVI_H
#define DOVI_H
#define RPU_PARSER_MAJOR 3
#define RPU_PARSER_MINOR 3
#define RPU_PARSER_PATCH 2
#include <stddef.h>
#include <stdint.h>
#include <stdlib.h>
#include <stdbool.h>
#define DoviNUM_COMPONENTS 3
/**
* Opaque Dolby Vision RPU.
*
* Use dovi_rpu_free to free.
* It should be freed regardless of whether or not an error occurred.
*/
typedef struct DoviRpuOpaque DoviRpuOpaque;
/**
* Struct representing a data buffer
*/
typedef struct {
/**
* Pointer to the data buffer
*/
const uint8_t *data;
/**
* Data buffer size
*/
size_t len;
} DoviData;
/**
* C struct for rpu_data_header()
*/
typedef struct {
/**
* Profile guessed from the values in the header
*/
uint8_t guessed_profile;
/**
* Enhancement layer type (FEL or MEL) if the RPU is profile 7
* null pointer if not profile 7
*/
const char *el_type;
/**
* Deprecated since 3.2.0
* The field is not actually part of the RPU header
*/
uint8_t rpu_nal_prefix;
uint8_t rpu_type;
uint16_t rpu_format;
uint8_t vdr_rpu_profile;
uint8_t vdr_rpu_level;
bool vdr_seq_info_present_flag;
bool chroma_resampling_explicit_filter_flag;
uint8_t coefficient_data_type;
uint64_t coefficient_log2_denom;
uint8_t vdr_rpu_normalized_idc;
bool bl_video_full_range_flag;
uint64_t bl_bit_depth_minus8;
uint64_t el_bit_depth_minus8;
uint64_t vdr_bit_depth_minus8;
bool spatial_resampling_filter_flag;
uint8_t reserved_zero_3bits;
bool el_spatial_resampling_filter_flag;
bool disable_residual_flag;
bool vdr_dm_metadata_present_flag;
bool use_prev_vdr_rpu_flag;
uint64_t prev_vdr_rpu_id;
} DoviRpuDataHeader;
/**
* Struct representing a data buffer
*/
typedef struct {
/**
* Pointer to the data buffer. Can be null if length is zero.
*/
const uint16_t *data;
/**
* Data buffer size
*/
size_t len;
} DoviU16Data;
/**
* Struct representing a data buffer
*/
typedef struct {
/**
* Pointer to the data buffer. Can be null if length is zero.
*/
const uint64_t *data;
/**
* Data buffer size
*/
size_t len;
} DoviU64Data;
/**
* Struct representing a data buffer
*/
typedef struct {
/**
* Pointer to the data buffer
*/
const int64_t *data;
/**
* Data buffer size
*/
size_t len;
} DoviI64Data;
/**
* Struct representing a 2D data buffer
*/
typedef struct {
/**
* Pointer to the list of Data structs
*/
const DoviI64Data *const *list;
/**
* List length
*/
size_t len;
} DoviI64Data2D;
/**
* Struct representing a 2D data buffer
*/
typedef struct {
/**
* Pointer to the list of Data structs
*/
const DoviU64Data *const *list;
/**
* List length
*/
size_t len;
} DoviU64Data2D;
typedef struct {
DoviU64Data poly_order_minus1;
DoviData linear_interp_flag;
DoviI64Data2D poly_coef_int;
DoviU64Data2D poly_coef;
} DoviPolynomialCurve;
/**
* Struct representing a 3D data buffer
*/
typedef struct {
/**
* Pointer to the list of I64Data2D structs
*/
const DoviI64Data2D *const *list;
/**
* List length
*/
size_t len;
} DoviI64Data3D;
/**
* Struct representing a 3D data buffer
*/
typedef struct {
/**
* Pointer to the list of U64Data2D structs
*/
const DoviU64Data2D *const *list;
/**
* List length
*/
size_t len;
} DoviU64Data3D;
typedef struct {
DoviData mmr_order_minus1;
DoviI64Data mmr_constant_int;
DoviU64Data mmr_constant;
DoviI64Data3D mmr_coef_int;
DoviU64Data3D mmr_coef;
} DoviMMRCurve;
typedef struct {
/**
* [2, 9]
*/
uint64_t num_pivots_minus2;
DoviU16Data pivots;
/**
* Consistent for a component
* Luma (component 0): Polynomial = 0
* Chroma (components 1 and 2): MMR = 1
*/
uint8_t mapping_idc;
/**
* mapping_idc = 0, null pointer otherwise
*/
const DoviPolynomialCurve *polynomial;
/**
* mapping_idc = 1, null pointer otherwise
*/
const DoviMMRCurve *mmr;
} DoviReshapingCurve;
/**
* C struct for rpu_data_nlq()
*/
typedef struct {
uint16_t nlq_offset[DoviNUM_COMPONENTS];
uint64_t vdr_in_max_int[DoviNUM_COMPONENTS];
uint64_t vdr_in_max[DoviNUM_COMPONENTS];
uint64_t linear_deadzone_slope_int[DoviNUM_COMPONENTS];
uint64_t linear_deadzone_slope[DoviNUM_COMPONENTS];
uint64_t linear_deadzone_threshold_int[DoviNUM_COMPONENTS];
uint64_t linear_deadzone_threshold[DoviNUM_COMPONENTS];
} DoviRpuDataNlq;
/**
* C struct for rpu_data_mapping()
*/
typedef struct {
uint64_t vdr_rpu_id;
uint64_t mapping_color_space;
uint64_t mapping_chroma_format_idc;
uint64_t num_x_partitions_minus1;
uint64_t num_y_partitions_minus1;
DoviReshapingCurve curves[DoviNUM_COMPONENTS];
/**
* Set to -1 to represent Option::None
*/
int32_t nlq_method_idc;
/**
* Set to -1 to represent Option::None
*/
int32_t nlq_num_pivots_minus2;
/**
* Length of zero when not present. Only present in profile 4 and 7.
*/
DoviU16Data nlq_pred_pivot_value;
/**
* Pointer to `RpuDataNlq` struct, null if not dual layer profile
*/
const DoviRpuDataNlq *nlq;
} DoviRpuDataMapping;
/**
* Statistical analysis of the frame: min, max, avg brightness.
*/
typedef struct {
uint16_t min_pq;
uint16_t max_pq;
uint16_t avg_pq;
} DoviExtMetadataBlockLevel1;
/**
* Creative intent trim passes per target display peak brightness
*/
typedef struct {
uint16_t target_max_pq;
uint16_t trim_slope;
uint16_t trim_offset;
uint16_t trim_power;
uint16_t trim_chroma_weight;
uint16_t trim_saturation_gain;
int16_t ms_weight;
} DoviExtMetadataBlockLevel2;
typedef struct {
/**
* Pointer to the list of ExtMetadataBlockLevel2 structs
*/
const DoviExtMetadataBlockLevel2 *const *list;
/**
* List length
*/
size_t len;
} DoviLevel2BlockList;
/**
* Level 1 offsets.
*/
typedef struct {
uint16_t min_pq_offset;
uint16_t max_pq_offset;
uint16_t avg_pq_offset;
} DoviExtMetadataBlockLevel3;
/**
* Something about temporal stability
*/
typedef struct {
uint16_t anchor_pq;
uint16_t anchor_power;
} DoviExtMetadataBlockLevel4;
/**
* Active area of the picture (letterbox, aspect ratio)
*/
typedef struct {
uint16_t active_area_left_offset;
uint16_t active_area_right_offset;
uint16_t active_area_top_offset;
uint16_t active_area_bottom_offset;
} DoviExtMetadataBlockLevel5;
/**
* ST2086/HDR10 metadata fallback
*/
typedef struct {
uint16_t max_display_mastering_luminance;
uint16_t min_display_mastering_luminance;
uint16_t max_content_light_level;
uint16_t max_frame_average_light_level;
} DoviExtMetadataBlockLevel6;
/**
* Creative intent trim passes per target display peak brightness
* For CM v4.0, L8 metadata only is present and used to compute L2
*
* This block can have varying byte lengths: 10, 12, 13, 19, 25
* Depending on the length, the fields parsed default to zero and may not be set.
* Up to (including):
* - 10: ms_weight
* - 12: target_mid_contrast
* - 13: clip_trim
* - 19: saturation_vector_field[0-5]
* - 25: hue_vector_field[0-5]
*/
typedef struct {
uint64_t length;
uint8_t target_display_index;
uint16_t trim_slope;
uint16_t trim_offset;
uint16_t trim_power;
uint16_t trim_chroma_weight;
uint16_t trim_saturation_gain;
uint16_t ms_weight;
uint16_t target_mid_contrast;
uint16_t clip_trim;
uint8_t saturation_vector_field0;
uint8_t saturation_vector_field1;
uint8_t saturation_vector_field2;
uint8_t saturation_vector_field3;
uint8_t saturation_vector_field4;
uint8_t saturation_vector_field5;
uint8_t hue_vector_field0;
uint8_t hue_vector_field1;
uint8_t hue_vector_field2;
uint8_t hue_vector_field3;
uint8_t hue_vector_field4;
uint8_t hue_vector_field5;
} DoviExtMetadataBlockLevel8;
typedef struct {
/**
* Pointer to the list of ExtMetadataBlockLevel8 structs
*/
const DoviExtMetadataBlockLevel8 *const *list;
/**
* List length
*/
size_t len;
} DoviLevel8BlockList;
/**
* Source/mastering display color primaries
*
* This block can have varying byte lengths: 1 or 17
* Depending on the length, the fields parsed default to zero and may not be set.
* Up to (including):
* - 1: source_primary_index
* - 17: source_primary_{red,green,blue,white}_{x,y}
*/
typedef struct {
uint64_t length;
uint8_t source_primary_index;
uint16_t source_primary_red_x;
uint16_t source_primary_red_y;
uint16_t source_primary_green_x;
uint16_t source_primary_green_y;
uint16_t source_primary_blue_x;
uint16_t source_primary_blue_y;
uint16_t source_primary_white_x;
uint16_t source_primary_white_y;
} DoviExtMetadataBlockLevel9;
/**
* Custom target display information
*
* This block can have varying byte lengths: 5 or 21
* Depending on the length, the fields parsed default to zero and may not be set.
* Up to (including):
* - 5: target_primary_index
* - 21: target_primary_{red,green,blue,white}_{x,y}
*/
typedef struct {
uint64_t length;
uint8_t target_display_index;
uint16_t target_max_pq;
uint16_t target_min_pq;
uint8_t target_primary_index;
uint16_t target_primary_red_x;
uint16_t target_primary_red_y;
uint16_t target_primary_green_x;
uint16_t target_primary_green_y;
uint16_t target_primary_blue_x;
uint16_t target_primary_blue_y;
uint16_t target_primary_white_x;
uint16_t target_primary_white_y;
} DoviExtMetadataBlockLevel10;
typedef struct {
/**
* Pointer to the list of ExtMetadataBlockLevel10 structs
*/
const DoviExtMetadataBlockLevel10 *const *list;
/**
* List length
*/
size_t len;
} DoviLevel10BlockList;
/**
* Content type metadata level
*/
typedef struct {
uint8_t content_type;
uint8_t whitepoint;
bool reference_mode_flag;
uint8_t reserved_byte2;
uint8_t reserved_byte3;
} DoviExtMetadataBlockLevel11;
/**
* Metadata level present in CM v4.0
*/
typedef struct {
uint8_t dm_mode;
uint8_t dm_version_index;
} DoviExtMetadataBlockLevel254;
/**
* Metadata level optionally present in CM v2.9.
* Different display modes (calibration/verify/bypass), debugging
*/
typedef struct {
uint8_t dm_run_mode;
uint8_t dm_run_version;
uint8_t dm_debug0;
uint8_t dm_debug1;
uint8_t dm_debug2;
uint8_t dm_debug3;
} DoviExtMetadataBlockLevel255;
/**
* C struct for the list of ext_metadata_block()
*/
typedef struct {
/**
* Number of metadata blocks
*/
uint64_t num_ext_blocks;
const DoviExtMetadataBlockLevel1 *level1;
DoviLevel2BlockList level2;
const DoviExtMetadataBlockLevel3 *level3;
const DoviExtMetadataBlockLevel4 *level4;
const DoviExtMetadataBlockLevel5 *level5;
const DoviExtMetadataBlockLevel6 *level6;
DoviLevel8BlockList level8;
const DoviExtMetadataBlockLevel9 *level9;
DoviLevel10BlockList level10;
const DoviExtMetadataBlockLevel11 *level11;
const DoviExtMetadataBlockLevel254 *level254;
const DoviExtMetadataBlockLevel255 *level255;
} DoviDmData;
/**
* C struct for vdr_dm_data()
*/
typedef struct {
bool compressed;
uint64_t affected_dm_metadata_id;
uint64_t current_dm_metadata_id;
uint64_t scene_refresh_flag;
int16_t ycc_to_rgb_coef0;
int16_t ycc_to_rgb_coef1;
int16_t ycc_to_rgb_coef2;
int16_t ycc_to_rgb_coef3;
int16_t ycc_to_rgb_coef4;
int16_t ycc_to_rgb_coef5;
int16_t ycc_to_rgb_coef6;
int16_t ycc_to_rgb_coef7;
int16_t ycc_to_rgb_coef8;
uint32_t ycc_to_rgb_offset0;
uint32_t ycc_to_rgb_offset1;
uint32_t ycc_to_rgb_offset2;
int16_t rgb_to_lms_coef0;
int16_t rgb_to_lms_coef1;
int16_t rgb_to_lms_coef2;
int16_t rgb_to_lms_coef3;
int16_t rgb_to_lms_coef4;
int16_t rgb_to_lms_coef5;
int16_t rgb_to_lms_coef6;
int16_t rgb_to_lms_coef7;
int16_t rgb_to_lms_coef8;
uint16_t signal_eotf;
uint16_t signal_eotf_param0;
uint16_t signal_eotf_param1;
uint32_t signal_eotf_param2;
uint8_t signal_bit_depth;
uint8_t signal_color_space;
uint8_t signal_chroma_format;
uint8_t signal_full_range_flag;
uint16_t source_min_pq;
uint16_t source_max_pq;
uint16_t source_diagonal;
DoviDmData dm_data;
} DoviVdrDmData;
/**
* Heap allocated list of valid RPU pointers
*/
typedef struct {
DoviRpuOpaque *const *list;
size_t len;
const char *error;
} DoviRpuOpaqueList;
#ifdef __cplusplus
extern "C" {
#endif // __cplusplus
/**
* # Safety
* The pointer to the data must be valid.
*
* Parse a Dolby Vision RPU from unescaped byte buffer.
* Adds an error if the parsing fails.
*/
DoviRpuOpaque *dovi_parse_rpu(const uint8_t *buf, size_t len);
/**
* # Safety
* The pointer to the data must be valid.
*
* Parse a Dolby Vision from a AV1 ITU-T T.35 metadata OBU byte buffer.
* Adds an error if the parsing fails.
*/
DoviRpuOpaque *dovi_parse_itu_t35_dovi_metadata_obu(const uint8_t *buf, size_t len);
/**
* # Safety
* The pointer to the data must be valid.
*
* Parse a Dolby Vision from a (possibly) escaped HEVC UNSPEC 62 NAL unit byte buffer.
* Adds an error if the parsing fails.
*/
DoviRpuOpaque *dovi_parse_unspec62_nalu(const uint8_t *buf, size_t len);
/**
* # Safety
* The pointer to the opaque struct must be valid.
* Avoid using on opaque pointers obtained through `dovi_parse_rpu_bin_file`.
*
* Free the RpuOpaque
*/
void dovi_rpu_free(DoviRpuOpaque *ptr);
/**
* # Safety
* The pointer to the opaque struct must be valid.
*
* Get the last logged error for the RpuOpaque operations.
*
* On invalid parsing, an error is added.
* The user should manually verify if there is an error, as the parsing does not return an error code.
*/
const char *dovi_rpu_get_error(const DoviRpuOpaque *ptr);
/**
* # Safety
* The data pointer should exist, and be allocated by Rust.
*
* Free a Data buffer
*/
void dovi_data_free(const DoviData *data);
/**
* # Safety
* The struct pointer must be valid.
*
* Writes the encoded RPU as a byte buffer.
* If an error occurs in the writing, it is logged to RpuOpaque.error
*/
const DoviData *dovi_write_rpu(DoviRpuOpaque *ptr);
/**
* # Safety
* The struct pointer must be valid.
*
* Writes the encoded RPU, escapes the bytes for HEVC and prepends the buffer with 0x7C01.
* If an error occurs in the writing, it is logged to RpuOpaque.error
*/
const DoviData *dovi_write_unspec62_nalu(DoviRpuOpaque *ptr);
/**
* # Safety
* The struct pointer must be valid.
* The mode must be between 0 and 4.
*
* Converts the RPU to be compatible with a different Dolby Vision profile.
* Possible modes:
* - 0: Don't modify the RPU
* - 1: Converts the RPU to be MEL compatible
* - 2: Converts the RPU to be profile 8.1 compatible. Both luma and chroma mapping curves are set to no-op.
* This mode handles source profiles 5, 7 and 8.
* - 3: Converts to static profile 8.4
* - 4: Converts to profile 8.1 preserving luma and chroma mapping. Old mode 2 behaviour.
*
* If an error occurs, it is logged to RpuOpaque.error.
* Returns 0 if successful, -1 otherwise.
*/
int32_t dovi_convert_rpu_with_mode(DoviRpuOpaque *ptr,
uint8_t mode);
/**
* # Safety
* The pointer to the opaque struct must be valid.
*
* Get the DoVi RPU header struct.
*/
const DoviRpuDataHeader *dovi_rpu_get_header(const DoviRpuOpaque *ptr);
/**
* # Safety
* The pointer to the struct must be valid.
*
* Frees the memory used by the RPU header.
*/
void dovi_rpu_free_header(const DoviRpuDataHeader *ptr);
/**
* # Safety
* The pointer to the opaque struct must be valid.
*
* Get the DoVi RpuDataMapping struct.
*/
const DoviRpuDataMapping *dovi_rpu_get_data_mapping(const DoviRpuOpaque *ptr);
/**
* # Safety
* The pointer to the struct must be valid.
*
* Frees the memory used by the RpuDataMapping.
*/
void dovi_rpu_free_data_mapping(const DoviRpuDataMapping *ptr);
/**
* # Safety
* The pointer to the opaque struct must be valid.
*
* Get the DoVi VdrDmData struct.
*/
const DoviVdrDmData *dovi_rpu_get_vdr_dm_data(const DoviRpuOpaque *ptr);
/**
* # Safety
* The pointer to the struct must be valid.
*
* Frees the memory used by the VdrDmData struct.
*/
void dovi_rpu_free_vdr_dm_data(const DoviVdrDmData *ptr);
/**
* # Safety
* The pointer to the file path must be valid.
*
* Parses an existing RPU binary file.
*
* Returns the heap allocated `DoviRpuList` as a pointer.
* The returned pointer may be null, or the list could be empty if an error occurred.
*/
const DoviRpuOpaqueList *dovi_parse_rpu_bin_file(const char *path);
/**
* # Safety
* The pointer to the struct must be valid.
*
* Frees the memory used by the DoviRpuOpaqueList struct.
*/
void dovi_rpu_list_free(const DoviRpuOpaqueList *ptr);
/**
* # Safety
* The struct pointer must be valid.
*
* Sets the L5 metadata active area offsets.
* If there is no L5 block present, it is created with the offsets.
*/
int32_t dovi_rpu_set_active_area_offsets(DoviRpuOpaque *ptr,
uint16_t left,
uint16_t right,
uint16_t top,
uint16_t bottom);
/**
* # Safety
* The struct pointer must be valid.
*
* Converts the existing reshaping/mapping to become no-op.
*/
int32_t dovi_rpu_remove_mapping(DoviRpuOpaque *ptr);
/**
* # Safety
* The struct pointer must be valid.
*
* Writes the encoded RPU as `itu_t_t35_payload_bytes` for AV1 ITU-T T.35 metadata OBU
* If an error occurs in the writing, it is logged to RpuOpaque.error
*/
const DoviData *dovi_write_av1_rpu_metadata_obu_t35_payload(DoviRpuOpaque *ptr);
/**
* # Safety
* The struct pointer must be valid.
*
* Writes the encoded RPU a complete AV1 `metadata_itut_t35()` OBU
* If an error occurs in the writing, it is logged to RpuOpaque.error
*/
const DoviData *dovi_write_av1_rpu_metadata_obu_t35_complete(DoviRpuOpaque *ptr);
#ifdef __cplusplus
} // extern "C"
#endif // __cplusplus
#endif /* DOVI_H */
@@ -1,6 +1,7 @@
package com.edde746.plezy
import android.content.Intent
import android.net.Uri
import android.os.Build
import android.os.Bundle
import android.app.AppOpsManager
@@ -8,6 +9,11 @@ import android.app.PictureInPictureParams
import android.content.Context
import android.content.res.Configuration
import android.util.Rational
import android.view.KeyEvent
import android.view.ViewGroup
import android.view.inputmethod.InputMethodManager
import android.widget.FrameLayout
import androidx.core.content.FileProvider
import io.flutter.embedding.android.FlutterActivity
import io.flutter.embedding.android.RenderMode
import io.flutter.embedding.android.TransparencyMode
@@ -15,22 +21,75 @@ import io.flutter.embedding.engine.FlutterEngine
import io.flutter.plugin.common.MethodChannel
import com.edde746.plezy.exoplayer.ExoPlayerPlugin
import com.edde746.plezy.mpv.MpvPlayerPlugin
import com.edde746.plezy.shared.ThemeHelper
import com.edde746.plezy.watchnext.WatchNextPlugin
import java.io.File
class MainActivity : FlutterActivity() {
private val PIP_CHANNEL = "app.plezy/pip"
private val PIP_CHANNEL = "com.plezy/pip"
private val EXTERNAL_PLAYER_CHANNEL = "com.plezy/external_player"
private val THEME_CHANNEL = "com.plezy/theme"
private var watchNextPlugin: WatchNextPlugin? = null
// Auto PiP state
private var autoPipReady = false
private var autoPipWidth: Int = 16
private var autoPipHeight: Int = 9
override fun onCreate(savedInstanceState: Bundle?) {
// Apply persisted theme color to the window background before anything
// else renders. This prevents a white flash between the native splash
// screen and Flutter's first frame for non-default themes (e.g. OLED).
val prefs = getSharedPreferences("plezy_prefs", Context.MODE_PRIVATE)
val savedTheme = prefs.getString("splash_theme", null)
ThemeHelper.themeColor(savedTheme)?.let { window.decorView.setBackgroundColor(it) }
super.onCreate(savedInstanceState)
// Disable the Android splash screen fade-out animation to avoid
// a flicker before Flutter draws its first frame.
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.S) {
splashScreen.setOnExitAnimationListener { splashScreenView -> splashScreenView.remove() }
}
// Disable Android's default focus highlight ring that appears when using
// D-pad navigation so the Flutter UI can render its own focus state.
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
window.decorView.defaultFocusHighlightEnabled = false
}
// Wrap the content view in a layout that intercepts DPAD key events
// before the IME input stage, which can consume DPAD direction events
// from virtual remotes before they reach Flutter's key handler.
val content = findViewById<ViewGroup>(android.R.id.content)
val wrapper = object : FrameLayout(this) {
override fun dispatchKeyEventPreIme(event: KeyEvent): Boolean {
when (event.keyCode) {
KeyEvent.KEYCODE_DPAD_UP,
KeyEvent.KEYCODE_DPAD_DOWN,
KeyEvent.KEYCODE_DPAD_LEFT,
KeyEvent.KEYCODE_DPAD_RIGHT,
KeyEvent.KEYCODE_DPAD_CENTER -> {
val imm = context.getSystemService(Context.INPUT_METHOD_SERVICE) as InputMethodManager
if (!imm.isAcceptingText) {
super.dispatchKeyEvent(event)
return true
}
}
}
return super.dispatchKeyEventPreIme(event)
}
}
while (content.childCount > 0) {
val child = content.getChildAt(0)
content.removeViewAt(0)
wrapper.addView(child)
}
content.addView(wrapper, ViewGroup.LayoutParams(
ViewGroup.LayoutParams.MATCH_PARENT,
ViewGroup.LayoutParams.MATCH_PARENT))
// Handle Watch Next deep link from initial launch
handleWatchNextIntent(intent)
}
@@ -65,6 +124,83 @@ class MainActivity : FlutterActivity() {
flutterEngine.plugins.add(MpvPlayerPlugin())
flutterEngine.plugins.add(ExoPlayerPlugin())
// External player: open local video files with proper content:// URIs
MethodChannel(flutterEngine.dartExecutor.binaryMessenger, EXTERNAL_PLAYER_CHANNEL).setMethodCallHandler { call, result ->
when (call.method) {
"openVideo" -> {
val filePath = call.argument<String>("filePath")
val packageName = call.argument<String>("package")
if (filePath == null) {
result.error("INVALID_ARGUMENT", "filePath is required", null)
return@setMethodCallHandler
}
try {
val uri: Uri
val grantRead: Boolean
if (filePath.startsWith("http://") || filePath.startsWith("https://")) {
uri = Uri.parse(filePath)
grantRead = false
} else if (filePath.startsWith("content://")) {
uri = Uri.parse(filePath)
grantRead = true
} else {
val path = if (filePath.startsWith("file://")) filePath.removePrefix("file://") else filePath
uri = FileProvider.getUriForFile(this, "com.edde746.plezy.fileprovider", File(path))
grantRead = true
}
val intent = Intent(Intent.ACTION_VIEW).apply {
setDataAndType(uri, "video/*")
addFlags(Intent.FLAG_ACTIVITY_NEW_TASK)
if (grantRead) {
addFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION)
}
if (packageName != null) {
setPackage(packageName)
}
}
startActivity(intent)
result.success(true)
} catch (e: android.content.ActivityNotFoundException) {
result.error("APP_NOT_FOUND", "No app found for package: $packageName", null)
} catch (e: Exception) {
result.error("LAUNCH_FAILED", e.message ?: e.javaClass.simpleName, null)
}
}
else -> result.notImplemented()
}
}
// Splash screen theme: persist user's chosen theme for next launch (API 31+)
MethodChannel(flutterEngine.dartExecutor.binaryMessenger, THEME_CHANNEL).setMethodCallHandler { call, result ->
when (call.method) {
"setSplashTheme" -> {
val mode = call.argument<String>("mode")
// Persist for next cold start & update window background now
getSharedPreferences("plezy_prefs", Context.MODE_PRIVATE)
.edit().putString("splash_theme", mode).apply()
ThemeHelper.themeColor(mode)?.let { window.decorView.setBackgroundColor(it) }
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.S) {
val themeId = when (mode) {
"dark" -> R.style.SplashTheme_Dark
"oled" -> R.style.SplashTheme_Oled
"light" -> R.style.SplashTheme_Light
"system" -> android.content.res.Resources.ID_NULL
else -> android.content.res.Resources.ID_NULL
}
splashScreen.setSplashScreenTheme(themeId)
}
result.success(true)
}
else -> result.notImplemented()
}
}
// Register Watch Next plugin and keep reference for deep link handling
watchNextPlugin = WatchNextPlugin()
flutterEngine.plugins.add(watchNextPlugin!!)
@@ -80,15 +216,7 @@ class MainActivity : FlutterActivity() {
return@setMethodCallHandler
}
// Check if PiP permission is granted via AppOpsManager
val appOpsManager = getSystemService(Context.APP_OPS_SERVICE) as AppOpsManager
val pipAllowed = appOpsManager.checkOpNoThrow(
AppOpsManager.OPSTR_PICTURE_IN_PICTURE,
applicationInfo.uid,
packageName
) == AppOpsManager.MODE_ALLOWED
if (!pipAllowed) {
if (!isPipPermissionGranted()) {
result.success(mapOf("success" to false, "errorCode" to "permission_disabled"))
return@setMethodCallHandler
}
@@ -96,31 +224,10 @@ class MainActivity : FlutterActivity() {
try {
val width = call.argument<Int>("width") ?: 16
val height = call.argument<Int>("height") ?: 9
// Android PiP requires aspect ratio between 0.418410 (5:12) and 2.39 (12:5)
val ratio = width.toFloat() / height.toFloat()
val clampedWidth: Int
val clampedHeight: Int
when {
ratio < 0.42f -> {
// Too tall - clamp to minimum ratio (5:12)
clampedWidth = 5
clampedHeight = 12
}
ratio > 2.39f -> {
// Too wide - clamp to maximum ratio (12:5)
clampedWidth = 12
clampedHeight = 5
}
else -> {
clampedWidth = width
clampedHeight = height
}
}
val clamped = clampAspectRatio(width, height)
val params = PictureInPictureParams.Builder()
.setAspectRatio(Rational(clampedWidth, clampedHeight))
.setAspectRatio(Rational(clamped.first, clamped.second))
.build()
val success = enterPictureInPictureMode(params)
if (success) {
@@ -133,18 +240,74 @@ class MainActivity : FlutterActivity() {
} catch (e: Exception) {
result.success(mapOf("success" to false, "errorCode" to "unknown", "errorMessage" to (e.message ?: "Unknown error")))
}
} else -> result.notImplemented()
}
"setAutoPipReady" -> {
autoPipReady = call.argument<Boolean>("ready") ?: false
autoPipWidth = call.argument<Int>("width") ?: 16
autoPipHeight = call.argument<Int>("height") ?: 9
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.S) {
try {
val clamped = clampAspectRatio(autoPipWidth, autoPipHeight)
val params = PictureInPictureParams.Builder()
.setAspectRatio(Rational(clamped.first, clamped.second))
.setAutoEnterEnabled(autoPipReady)
.build()
setPictureInPictureParams(params)
} catch (_: Exception) {}
}
result.success(true)
}
else -> result.notImplemented()
}
}
}
override fun onPictureInPictureModeChanged(isInPictureInPictureMode: Boolean,newConfig: Configuration) {
super.onPictureInPictureModeChanged(isInPictureInPictureMode, newConfig)
MethodChannel( flutterEngine!!.dartExecutor.binaryMessenger, PIP_CHANNEL ).invokeMethod( "onPipChanged" , isInPictureInPictureMode)
flutterEngine?.let { engine ->
MethodChannel(engine.dartExecutor.binaryMessenger, PIP_CHANNEL).invokeMethod("onPipChanged", isInPictureInPictureMode)
engine.plugins.get(ExoPlayerPlugin::class.java)?.let { plugin ->
(plugin as? ExoPlayerPlugin)?.onPipModeChanged(isInPictureInPictureMode)
}
}
}
// Notify ExoPlayer plugin to resize video surface for PiP
flutterEngine?.plugins?.get(ExoPlayerPlugin::class.java)?.let { plugin ->
(plugin as? ExoPlayerPlugin)?.onPipModeChanged(isInPictureInPictureMode)
override fun onUserLeaveHint() {
super.onUserLeaveHint()
// Auto PiP for API 26-30 (API 31+ uses setAutoEnterEnabled)
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O &&
Build.VERSION.SDK_INT < Build.VERSION_CODES.S &&
autoPipReady && isPipPermissionGranted()) {
try {
// Notify Flutter to prepare video filter before PiP
flutterEngine?.dartExecutor?.binaryMessenger?.let { messenger ->
MethodChannel(messenger, PIP_CHANNEL).invokeMethod("onAutoPipEntering", null)
}
val clamped = clampAspectRatio(autoPipWidth, autoPipHeight)
val params = PictureInPictureParams.Builder()
.setAspectRatio(Rational(clamped.first, clamped.second))
.build()
enterPictureInPictureMode(params)
} catch (_: Exception) {}
}
}
private fun isPipPermissionGranted(): Boolean {
val appOpsManager = getSystemService(Context.APP_OPS_SERVICE) as AppOpsManager
return appOpsManager.checkOpNoThrow(
AppOpsManager.OPSTR_PICTURE_IN_PICTURE,
applicationInfo.uid,
packageName
) == AppOpsManager.MODE_ALLOWED
}
private fun clampAspectRatio(width: Int, height: Int): Pair<Int, Int> {
val ratio = width.toFloat() / height.toFloat()
return when {
ratio < 0.42f -> Pair(5, 12)
ratio > 2.39f -> Pair(12, 5)
else -> Pair(width, height)
}
}
}
@@ -0,0 +1,85 @@
package com.edde746.plezy.exoplayer
import android.media.MediaCodecInfo
import android.media.MediaCodecList
import android.os.Build
import android.util.Log
enum class DvConversionMode { DISABLED, DV81, HEVC_STRIP }
object DoviBridge {
private const val TAG = "DoviBridge"
private val nativeLoaded: Boolean by lazy {
try {
System.loadLibrary("dovi_bridge")
true
} catch (_: UnsatisfiedLinkError) {
Log.w(TAG, "Native lib not found")
false
}
}
fun isAvailable(): Boolean = nativeLoaded &&
runCatching { nativeIsConversionPathReady() }.getOrDefault(false)
private fun deviceSupportsDvProfile(profile: Int, minApi: Int = 0): Boolean {
try {
if (Build.VERSION.SDK_INT < minApi) return false
val codecList = MediaCodecList(MediaCodecList.REGULAR_CODECS)
return codecList.codecInfos.any { info ->
!info.isEncoder && info.supportedTypes.any { type ->
type.equals("video/dolby-vision", ignoreCase = true) &&
info.getCapabilitiesForType(type).profileLevels.any { it.profile == profile }
}
}
} catch (e: Exception) {
Log.w(TAG, "Failed to query DV profile $profile support", e)
return false
}
}
val deviceSupportsDvProfile7: Boolean by lazy {
deviceSupportsDvProfile(MediaCodecInfo.CodecProfileLevel.DolbyVisionProfileDvheDtr)
.also { Log.i(TAG, "Device DV Profile 7 support: $it") }
}
val deviceSupportsDvProfile8: Boolean by lazy {
deviceSupportsDvProfile(MediaCodecInfo.CodecProfileLevel.DolbyVisionProfileDvheSt, minApi = 27)
.also { Log.i(TAG, "Device DV Profile 8 support: $it") }
}
fun getConversionMode(): DvConversionMode = when {
!isAvailable() -> DvConversionMode.DISABLED
deviceSupportsDvProfile7 -> DvConversionMode.DISABLED // try native first; ExoPlayerCore retries with conversion on failure
deviceSupportsDvProfile8 -> DvConversionMode.DV81
else -> DvConversionMode.HEVC_STRIP
}
/** Get the fallback mode when native DV7 decoding fails. */
fun getDv7FallbackMode(): DvConversionMode = when {
deviceSupportsDvProfile8 -> DvConversionMode.DV81
else -> DvConversionMode.HEVC_STRIP
}
fun convertRpuNalu(payload: ByteArray, mode: Int = 2): ByteArray? {
if (!isAvailable() || payload.isEmpty()) return null
return runCatching { nativeConvertDv7RpuToDv81(payload, mode) }
.onFailure { Log.w(TAG, "RPU conversion failed: ${it.message}") }
.getOrNull()
}
fun getVersion(): String? {
if (!nativeLoaded) return null
return runCatching { nativeGetBridgeVersion() }.getOrNull()
}
@JvmStatic
private external fun nativeConvertDv7RpuToDv81(payload: ByteArray, mode: Int): ByteArray?
@JvmStatic
private external fun nativeIsConversionPathReady(): Boolean
@JvmStatic
private external fun nativeGetBridgeVersion(): String
}
@@ -0,0 +1,362 @@
package com.edde746.plezy.exoplayer
import android.util.Log
import androidx.media3.common.DataReader
import androidx.media3.common.Format
import androidx.media3.common.MimeTypes
import androidx.media3.common.util.ParsableByteArray
import androidx.media3.extractor.TrackOutput
import java.io.ByteArrayOutputStream
/**
* TrackOutput wrapper that processes DV Profile 7 HEVC samples based on conversion mode:
*
* - DV81: Convert RPU NALs via libdovi to Profile 8.1, present as video/dolby-vision
* with dvhe.08.XX codec string. Preserves dynamic tone mapping metadata.
* - HEVC_STRIP: Strip all DV enhancement layers, present as plain video/hevc.
*
* Two modes of NAL framing (auto-detected):
* - Annex B (MKV path): MatroskaExtractor outputs 00 00 00 01 start codes
* - Length-prefixed (MP4 path): Mp4Extractor outputs 4-byte big-endian lengths
*
* NAL processing:
* - Type 62 (UNSPEC62): DV RPU → convert (DV81) or strip (HEVC_STRIP)
* - Type 63 (UNSPEC63): DV Enhancement Layer → strip
* - nuh_layer_id > 0: Enhancement layer NAL → strip
* - All retained NALs: normalize nuh_layer_id to 0
*/
class DoviConvertingTrackOutput(
private val delegate: TrackOutput,
private val dvMode: DvConversionMode = DvConversionMode.HEVC_STRIP,
) : TrackOutput {
companion object {
private const val TAG = "DoviConvertTrack"
private const val NAL_TYPE_UNSPEC62 = 62
private const val NAL_TYPE_UNSPEC63 = 63
private const val LIBDOVI_MODE_TO_81 = 2
private val ANNEX_B_START_CODE = byteArrayOf(0, 0, 0, 1)
}
var conversionActive = false
private set
var strippedNalCount = 0L
private set
var convertedRpuCount = 0L
private set
// Sample buffering between sampleData() and sampleMetadata()
private val sampleBuffer = ByteArrayOutputStream(256 * 1024)
private var buffering = false
override fun format(format: Format) {
if (!conversionActive) {
val codecs = format.codecs
if (codecs != null && codecs.startsWith("dvhe.07")) {
conversionActive = true
Log.i(TAG, "DV Profile 7 detected ($codecs), mode=$dvMode")
Log.i(TAG, "Original format: mime=${format.sampleMimeType}, codecs=$codecs, " +
"initData=${format.initializationData.size} entries " +
"(${format.initializationData.mapIndexed { i, d -> "$i:${d.size}B" }.joinToString()})")
val newFormat = when (dvMode) {
DvConversionMode.DV81 -> {
// Parse DV level from codec string: "dvhe.07.06" → 6
val level = codecs.split('.').getOrNull(2)?.toIntOrNull() ?: 6
val newCodecs = "dvhe.08.%02d".format(level)
val dvConfigRecord = buildDv81ConfigRecord(level)
Log.i(TAG, "DV81: rewriting to $newCodecs, config=${dvConfigRecord.size}B")
format.buildUpon()
.setSampleMimeType(MimeTypes.VIDEO_DOLBY_VISION)
.setCodecs(newCodecs)
.setInitializationData(
if (format.initializationData.isNotEmpty())
listOf(format.initializationData[0], dvConfigRecord)
else
listOf(ByteArray(0), dvConfigRecord)
)
.build()
}
else -> {
// HEVC_STRIP: present as plain HEVC
Log.i(TAG, "HEVC_STRIP: rewriting to video/hevc")
format.buildUpon()
.setSampleMimeType(MimeTypes.VIDEO_H265)
.setCodecs(null)
.setInitializationData(
if (format.initializationData.isNotEmpty())
listOf(format.initializationData[0])
else
emptyList()
)
.build()
}
}
Log.i(TAG, "Rewritten format: mime=${newFormat.sampleMimeType}, " +
"codecs=${newFormat.codecs}, initData=${newFormat.initializationData.size} entries")
delegate.format(newFormat)
return
}
}
delegate.format(format)
}
override fun sampleData(
input: DataReader, length: Int, allowEndOfInput: Boolean, sampleDataPart: Int
): Int {
if (!conversionActive) {
return delegate.sampleData(input, length, allowEndOfInput, sampleDataPart)
}
// Buffer sample data for processing at sampleMetadata() time
buffering = true
val buf = ByteArray(length)
val bytesRead = input.read(buf, 0, length)
if (bytesRead > 0) {
sampleBuffer.write(buf, 0, bytesRead)
}
return bytesRead
}
override fun sampleData(data: ParsableByteArray, length: Int, sampleDataPart: Int) {
if (!conversionActive) {
delegate.sampleData(data, length, sampleDataPart)
return
}
// Buffer sample data for processing at sampleMetadata() time
buffering = true
val bytes = ByteArray(length)
data.readBytes(bytes, 0, length)
sampleBuffer.write(bytes, 0, length)
}
override fun sampleMetadata(
timeUs: Long, flags: Int, size: Int, offset: Int, cryptoData: TrackOutput.CryptoData?
) {
if (!conversionActive || !buffering) {
delegate.sampleMetadata(timeUs, flags, size, offset, cryptoData)
return
}
buffering = false
val rawSample = sampleBuffer.toByteArray()
sampleBuffer.reset()
val processed = try {
processNalUnits(rawSample)
} catch (e: Exception) {
Log.e(TAG, "NAL processing failed, passing raw sample", e)
rawSample
}
// Skip empty samples (all NALs were DV layers) — don't confuse the decoder
if (processed.isEmpty()) return
// Write processed data to delegate. Offset must be 0 since we write exactly
// the processed amount (no trailing data from next sample in the buffer).
val parsable = ParsableByteArray(processed, processed.size)
delegate.sampleData(parsable, processed.size, TrackOutput.SAMPLE_DATA_PART_MAIN)
delegate.sampleMetadata(timeUs, flags, processed.size, 0, cryptoData)
}
// Sample counter for periodic logging
private var sampleCount = 0L
/**
* Process a single NAL: convert RPU (DV81), strip DV layers, or keep.
* Returns processed NAL data to write, or null if stripped.
*/
private fun processNal(nalData: ByteArray): ByteArray? {
if (nalData.size < 2) return nalData
val nalType = (nalData[0].toInt() ushr 1) and 0x3F
val nuhLayerId = ((nalData[0].toInt() and 1) shl 5) or
((nalData[1].toInt() ushr 3) and 0x1F)
return when {
nalType == NAL_TYPE_UNSPEC62 && dvMode == DvConversionMode.DV81 -> {
val converted = DoviBridge.convertRpuNalu(nalData, LIBDOVI_MODE_TO_81)
if (converted != null) {
normalizeLayerId(converted)
convertedRpuCount++
converted
} else {
strippedNalCount++
null
}
}
nalType == NAL_TYPE_UNSPEC62 || nalType == NAL_TYPE_UNSPEC63 || nuhLayerId > 0 -> {
strippedNalCount++
null
}
else -> {
normalizeLayerId(nalData)
nalData
}
}
}
/**
* Process NAL units in the sample data. Auto-detects format:
* - Annex B (00 00 00 01 / 00 00 01 start codes) — used by MatroskaExtractor
* - Length-prefixed (4-byte big-endian length) — used by Mp4Extractor
*/
private fun processNalUnits(data: ByteArray): ByteArray {
if (data.size < 4) return data
// Auto-detect: Annex B starts with 00 00 00 01 or 00 00 01
val isAnnexB = (data.size >= 4 && data[0] == 0.toByte() && data[1] == 0.toByte() &&
data[2] == 0.toByte() && data[3] == 1.toByte()) ||
(data.size >= 3 && data[0] == 0.toByte() && data[1] == 0.toByte() &&
data[2] == 1.toByte())
if (sampleCount == 0L) {
Log.d(TAG, "NAL format detected: ${if (isAnnexB) "Annex B" else "length-prefixed"}, " +
"first bytes: ${data.take(8).joinToString(" ") { "%02X".format(it) }}")
}
return if (isAnnexB) processAnnexBNals(data) else processLengthPrefixedNals(data)
}
/**
* Find all Annex B start code positions (00 00 01 or 00 00 00 01) in the data.
* Returns list of pairs: (startCodeEnd, startCodeLen) where startCodeEnd is the
* byte index right after the start code, and startCodeLen is 3 or 4.
*/
private fun findAnnexBStartCodes(data: ByteArray): List<Pair<Int, Int>> {
val positions = mutableListOf<Pair<Int, Int>>()
var i = 0
while (i < data.size - 2) {
if (data[i] == 0.toByte() && data[i + 1] == 0.toByte()) {
if (i + 3 < data.size && data[i + 2] == 0.toByte() && data[i + 3] == 1.toByte()) {
positions.add(Pair(i + 4, 4))
i += 4
continue
} else if (data[i + 2] == 1.toByte()) {
positions.add(Pair(i + 3, 3))
i += 3
continue
}
}
i++
}
return positions
}
/** Process Annex B formatted NAL units (MKV path). */
private fun processAnnexBNals(data: ByteArray): ByteArray {
val output = ByteArrayOutputStream(data.size)
var kept = 0
var stripped = 0
val startCodes = findAnnexBStartCodes(data)
if (startCodes.isEmpty()) {
sampleCount++
return data
}
for (idx in startCodes.indices) {
val nalStart = startCodes[idx].first
val nalEnd = if (idx + 1 < startCodes.size) {
startCodes[idx + 1].first - startCodes[idx + 1].second
} else {
data.size
}
if (nalEnd <= nalStart) continue
val result = processNal(data.copyOfRange(nalStart, nalEnd))
if (result != null) {
output.write(ANNEX_B_START_CODE)
output.write(result)
kept++
} else {
stripped++
}
}
sampleCount++
if (sampleCount <= 3 || (sampleCount % 500 == 0L)) {
Log.d(TAG, "Sample #$sampleCount (AnnexB): ${data.size}B -> ${output.size()}B, " +
"kept=$kept stripped=$stripped NALs")
}
return output.toByteArray()
}
/** Process length-prefixed NAL units (MP4 path). */
private fun processLengthPrefixedNals(data: ByteArray): ByteArray {
val output = ByteArrayOutputStream(data.size)
var pos = 0
var kept = 0
var stripped = 0
while (pos + 4 <= data.size) {
val nalLen = ((data[pos].toInt() and 0xFF) shl 24) or
((data[pos + 1].toInt() and 0xFF) shl 16) or
((data[pos + 2].toInt() and 0xFF) shl 8) or
(data[pos + 3].toInt() and 0xFF)
if (nalLen <= 0 || pos + 4 + nalLen > data.size) {
if (sampleCount < 5) {
Log.w(TAG, "Bad NAL length $nalLen at pos $pos (data.size=${data.size})")
}
break
}
val result = processNal(data.copyOfRange(pos + 4, pos + 4 + nalLen))
if (result != null) {
writeLengthPrefixedNal(output, result)
kept++
} else {
stripped++
}
pos += 4 + nalLen
}
sampleCount++
if (sampleCount <= 3 || (sampleCount % 500 == 0L)) {
Log.d(TAG, "Sample #$sampleCount (LenPrefix): ${data.size}B -> ${output.size()}B, " +
"kept=$kept stripped=$stripped NALs")
}
return output.toByteArray()
}
private fun normalizeLayerId(nalData: ByteArray) {
if (nalData.size >= 2) {
nalData[0] = (nalData[0].toInt() and 0xFE).toByte() // Clear bit 0 of byte 0
nalData[1] = (nalData[1].toInt() and 0x07).toByte() // Clear bits 7-3 of byte 1
}
}
private fun writeLengthPrefixedNal(output: ByteArrayOutputStream, nalData: ByteArray) {
val len = nalData.size
output.write((len ushr 24) and 0xFF)
output.write((len ushr 16) and 0xFF)
output.write((len ushr 8) and 0xFF)
output.write(len and 0xFF)
output.write(nalData)
}
/**
* Build a 24-byte DOVIDecoderConfigurationRecord for DV Profile 8.1.
*
* Binary layout (from Dolby Vision spec):
* byte[0]: dv_version_major = 1
* byte[1]: dv_version_minor = 0
* byte[2]: dv_profile (7 bits) | dv_level MSB (1 bit)
* byte[3]: dv_level low 5 bits (5 bits) | rpu_present (1) | el_present (1) | bl_present (1)
* byte[4]: bl_compatibility_id (4 bits) | md_compression (2 bits) | reserved (2 bits)
* byte[5-23]: reserved (zeros)
*/
private fun buildDv81ConfigRecord(level: Int): ByteArray {
val record = ByteArray(24)
record[0] = 0x01 // dv_version_major = 1
record[1] = 0x00 // dv_version_minor = 0
record[2] = ((8 shl 1) or ((level ushr 5) and 0x01)).toByte() // profile=8 | level MSB
record[3] = (((level and 0x1F) shl 3) or 0x05).toByte() // level low 5 | rpu=1 el=0 bl=1
record[4] = (1 shl 4).toByte() // bl_compatibility_id=1 (HDR10)
// bytes 5-23 remain 0 (reserved)
return record
}
}
@@ -0,0 +1,60 @@
package com.edde746.plezy.exoplayer
import androidx.media3.common.C
import androidx.media3.extractor.Extractor
import androidx.media3.extractor.ExtractorInput
import androidx.media3.extractor.ExtractorOutput
import androidx.media3.extractor.PositionHolder
import androidx.media3.extractor.SeekMap
import androidx.media3.extractor.TrackOutput
/**
* ExtractorOutput wrapper that intercepts video track creation
* to insert DoviConvertingTrackOutput for DV processing.
* Shared by DoviExtractorWrapper for both MP4 and MKV containers.
*/
class DoviExtractorOutputWrapper(
private val delegate: ExtractorOutput,
private val dvMode: DvConversionMode,
private val onVideoTrackWrapped: (DoviConvertingTrackOutput) -> Unit,
) : ExtractorOutput {
override fun track(id: Int, type: Int): TrackOutput {
val original = delegate.track(id, type)
if (type == C.TRACK_TYPE_VIDEO) {
val wrapper = DoviConvertingTrackOutput(original, dvMode)
onVideoTrackWrapped(wrapper)
return wrapper
}
return original
}
override fun endTracks() = delegate.endTracks()
override fun seekMap(seekMap: SeekMap) = delegate.seekMap(seekMap)
}
/**
* Extractor decorator for Mp4/FragmentedMp4 containers.
* Wraps the video TrackOutput with DoviConvertingTrackOutput to perform
* DV Profile 7 → 8.1 conversion via inline NAL processing.
*/
class DoviExtractorWrapper(
private val delegate: Extractor,
private val dvMode: DvConversionMode = DvConversionMode.HEVC_STRIP,
) : Extractor {
@Volatile var doviTrackOutput: DoviConvertingTrackOutput? = null
private set
override fun sniff(input: ExtractorInput): Boolean = delegate.sniff(input)
override fun init(output: ExtractorOutput) {
delegate.init(DoviExtractorOutputWrapper(output, dvMode) { doviTrackOutput = it })
}
override fun read(input: ExtractorInput, seekPosition: PositionHolder): Int =
delegate.read(input, seekPosition)
override fun seek(position: Long, timeUs: Long) = delegate.seek(position, timeUs)
override fun release() = delegate.release()
}
File diff suppressed because it is too large Load Diff
@@ -1,10 +1,11 @@
package com.edde746.plezy.exoplayer
import android.app.Activity
import android.app.ActivityManager
import android.content.Context
import android.net.Uri
import android.util.Log
import com.edde746.plezy.mpv.MpvPlayerCore
import com.edde746.plezy.mpv.MpvPlayerDelegate
import io.flutter.embedding.engine.plugins.FlutterPlugin
import io.flutter.embedding.engine.plugins.activity.ActivityAware
import io.flutter.embedding.engine.plugins.activity.ActivityPluginBinding
@@ -13,7 +14,7 @@ import io.flutter.plugin.common.MethodCall
import io.flutter.plugin.common.MethodChannel
class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
EventChannel.StreamHandler, ActivityAware, ExoPlayerDelegate, MpvPlayerDelegate {
EventChannel.StreamHandler, ActivityAware, ExoPlayerDelegate {
companion object {
private const val TAG = "ExoPlayerPlugin"
@@ -27,8 +28,14 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
private var playerCore: ExoPlayerCore? = null
private var mpvCore: MpvPlayerCore? = null // MPV fallback player
private var usingMpvFallback: Boolean = false
private var fallbackInProgress: Boolean = false
private var activity: Activity? = null
private var activityBinding: ActivityPluginBinding? = null
private val nameToId = mutableMapOf<String, Int>()
private var configuredBufferSizeBytes: Int? = null
private var debugLoggingEnabled: Boolean = false
private val pendingMpvProperties = mutableListOf<Pair<String, String>>()
// FlutterPlugin
@@ -62,6 +69,7 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
mpvCore?.dispose()
mpvCore = null
usingMpvFallback = false
fallbackInProgress = false
activity = null
activityBinding = null
Log.d(TAG, "Detached from activity")
@@ -95,7 +103,7 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
override fun onMethodCall(call: MethodCall, result: MethodChannel.Result) {
when (call.method) {
"initialize" -> handleInitialize(result)
"initialize" -> handleInitialize(call, result)
"dispose" -> handleDispose(result)
"open" -> handleOpen(call, result)
"play" -> handlePlay(result)
@@ -118,12 +126,24 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
)
"getStats" -> handleGetStats(result)
"getPlayerType" -> result.success(if (usingMpvFallback) "mpv" else "exoplayer")
"getHeapSize" -> {
val am = activity?.getSystemService(Context.ACTIVITY_SERVICE) as? ActivityManager
result.success(am?.largeMemoryClass ?: 0)
}
"setSubtitleStyle" -> handleSetSubtitleStyle(call, result)
"observeProperty" -> handleObserveProperty(call, result)
"setMpvProperty" -> handleSetMpvProperty(call, result)
"setLogLevel" -> {
val level = call.argument<String>("level") ?: "warn"
debugLoggingEnabled = (level == "v" || level == "debug" || level == "trace")
playerCore?.debugLoggingEnabled = debugLoggingEnabled
result.success(null)
}
else -> result.notImplemented()
}
}
private fun handleInitialize(result: MethodChannel.Result) {
private fun handleInitialize(call: MethodCall, result: MethodChannel.Result) {
val currentActivity = activity
if (currentActivity == null) {
result.error("NO_ACTIVITY", "Activity not available", null)
@@ -136,12 +156,20 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
return
}
val bufferSizeBytes = call.argument<Int>("bufferSizeBytes")
val tunnelingEnabled = call.argument<Boolean>("tunnelingEnabled") ?: true
configuredBufferSizeBytes = bufferSizeBytes
currentActivity.runOnUiThread {
try {
playerCore = ExoPlayerCore(currentActivity).apply {
delegate = this@ExoPlayerPlugin
this.debugLoggingEnabled = this@ExoPlayerPlugin.debugLoggingEnabled
}
val success = playerCore?.initialize() ?: false
val success = playerCore?.initialize(
bufferSizeBytes = bufferSizeBytes,
tunnelingEnabled = tunnelingEnabled,
) ?: false
// Start hidden
playerCore?.setVisible(false)
@@ -157,14 +185,12 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
private fun handleDispose(result: MethodChannel.Result) {
activity?.runOnUiThread {
if (usingMpvFallback) {
mpvCore?.dispose()
mpvCore = null
} else {
playerCore?.dispose()
playerCore = null
}
playerCore?.dispose()
playerCore = null
mpvCore?.dispose()
mpvCore = null
usingMpvFallback = false
fallbackInProgress = false
Log.d(TAG, "Disposed")
result.success(null)
} ?: result.success(null)
@@ -175,12 +201,16 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
val headers = call.argument<Map<String, String>>("headers")
val startPositionMs = call.argument<Number>("startPositionMs")?.toLong() ?: 0L
val autoPlay = call.argument<Boolean>("autoPlay") ?: true
val isLive = call.argument<Boolean>("isLive") ?: false
if (uri == null) {
result.error("INVALID_ARGS", "Missing 'uri'", null)
return
}
// New media = fresh slate for pending MPV properties
pendingMpvProperties.clear()
activity?.runOnUiThread {
if (usingMpvFallback) {
// MPV: Build loadfile command with options
@@ -194,9 +224,11 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
val optionsStr = options.joinToString(",")
// Convert content:// URIs to fdclose:// for MPV (SAF SD card downloads)
val mpvUri = openContentFd(uri)?.let { "fdclose://$it" } ?: uri
mpvCore?.command(arrayOf("loadfile", mpvUri, "replace", "-1", optionsStr))
mpvCore?.runOnExecutor {
mpvCore?.command(arrayOf("loadfile", mpvUri, "replace", "-1", optionsStr))
}
} else {
playerCore?.open(uri, headers, startPositionMs, autoPlay)
playerCore?.open(uri, headers, startPositionMs, autoPlay, isLive)
}
result.success(null)
} ?: result.error("NO_ACTIVITY", "Activity not available", null)
@@ -205,7 +237,7 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
private fun handlePlay(result: MethodChannel.Result) {
activity?.runOnUiThread {
if (usingMpvFallback) {
mpvCore?.setProperty("pause", "no")
mpvCore?.runOnExecutor { mpvCore?.setProperty("pause", "no") }
} else {
playerCore?.play()
}
@@ -216,7 +248,7 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
private fun handlePause(result: MethodChannel.Result) {
activity?.runOnUiThread {
if (usingMpvFallback) {
mpvCore?.setProperty("pause", "yes")
mpvCore?.runOnExecutor { mpvCore?.setProperty("pause", "yes") }
} else {
playerCore?.pause()
}
@@ -227,8 +259,10 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
private fun handleStop(result: MethodChannel.Result) {
activity?.runOnUiThread {
if (usingMpvFallback) {
mpvCore?.command(arrayOf("stop"))
mpvCore?.setVisible(false)
mpvCore?.runOnExecutor {
mpvCore?.command(arrayOf("stop"))
mpvCore?.setVisible(false)
}
} else {
playerCore?.stop()
}
@@ -247,7 +281,9 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
activity?.runOnUiThread {
if (usingMpvFallback) {
val positionSeconds = positionMs / 1000.0
mpvCore?.command(arrayOf("seek", positionSeconds.toString(), "absolute"))
mpvCore?.runOnExecutor {
mpvCore?.command(arrayOf("seek", positionSeconds.toString(), "absolute"))
}
} else {
playerCore?.seekTo(positionMs)
}
@@ -265,7 +301,7 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
activity?.runOnUiThread {
if (usingMpvFallback) {
mpvCore?.setProperty("volume", volume.toString())
mpvCore?.runOnExecutor { mpvCore?.setProperty("volume", volume.toString()) }
} else {
playerCore?.setVolume(volume / 100f) // Convert 0-100 to 0-1
}
@@ -283,7 +319,7 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
activity?.runOnUiThread {
if (usingMpvFallback) {
mpvCore?.setProperty("speed", rate.toString())
mpvCore?.runOnExecutor { mpvCore?.setProperty("speed", rate.toString()) }
} else {
playerCore?.setPlaybackSpeed(rate)
}
@@ -303,7 +339,7 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
if (usingMpvFallback) {
// MPV uses numeric track IDs - extract from string format
val numericId = trackId.split("_").lastOrNull()?.toIntOrNull() ?: 1
mpvCore?.setProperty("aid", numericId.toString())
mpvCore?.runOnExecutor { mpvCore?.setProperty("aid", numericId.toString()) }
} else {
playerCore?.selectAudioTrack(trackId)
}
@@ -317,11 +353,13 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
// trackId can be null or "no" to disable subtitles
activity?.runOnUiThread {
if (usingMpvFallback) {
if (trackId == null || trackId == "no") {
mpvCore?.setProperty("sid", "no")
} else {
val numericId = trackId.split("_").lastOrNull()?.toIntOrNull() ?: 1
mpvCore?.setProperty("sid", numericId.toString())
mpvCore?.runOnExecutor {
if (trackId == null || trackId == "no") {
mpvCore?.setProperty("sid", "no")
} else {
val numericId = trackId.split("_").lastOrNull()?.toIntOrNull() ?: 1
mpvCore?.setProperty("sid", numericId.toString())
}
}
} else {
playerCore?.selectSubtitleTrack(trackId)
@@ -345,7 +383,9 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
activity?.runOnUiThread {
if (usingMpvFallback) {
val selectFlag = if (select) "select" else "auto"
mpvCore?.command(arrayOf("sub-add", uri, selectFlag, title ?: "External"))
mpvCore?.runOnExecutor {
mpvCore?.command(arrayOf("sub-add", uri, selectFlag, title ?: "External"))
}
} else {
playerCore?.addSubtitleTrack(uri, title, language, mimeType, select)
}
@@ -412,6 +452,19 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
result.success(null)
}
private fun handleObserveProperty(call: MethodCall, result: MethodChannel.Result) {
val name = call.argument<String>("name")
val id = call.argument<Int>("id")
if (name == null || id == null) {
result.error("INVALID_ARGS", "Missing 'name' or 'id'", null)
return
}
nameToId[name] = id
result.success(null)
}
private fun handleSetSubtitleStyle(call: MethodCall, result: MethodChannel.Result) {
val fontSize = call.argument<Number>("fontSize")?.toFloat() ?: 55f
val textColor = call.argument<String>("textColor") ?: "#FFFFFF"
@@ -419,6 +472,7 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
val borderColor = call.argument<String>("borderColor") ?: "#000000"
val bgColor = call.argument<String>("bgColor") ?: "#000000"
val bgOpacity = call.argument<Number>("bgOpacity")?.toInt() ?: 0
val subtitlePosition = call.argument<Number>("subtitlePosition")?.toInt() ?: 100
if (usingMpvFallback) {
// MPV fallback handles styling via setProperty, no-op here
@@ -426,21 +480,40 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
return
}
playerCore?.setSubtitleStyle(fontSize, textColor, borderSize, borderColor, bgColor, bgOpacity)
playerCore?.setSubtitleStyle(fontSize, textColor, borderSize, borderColor, bgColor, bgOpacity, subtitlePosition)
result.success(null)
}
private fun handleSetMpvProperty(call: MethodCall, result: MethodChannel.Result) {
val name = call.argument<String>("name")
val value = call.argument<String>("value")
if (name == null || value == null) {
result.error("INVALID_ARGS", "Missing 'name' or 'value'", null)
return
}
if (usingMpvFallback) {
mpvCore?.runOnExecutor { mpvCore?.setProperty(name, value) }
} else {
// Store for later application if ExoPlayer falls back to MPV
pendingMpvProperties.add(Pair(name, value))
}
result.success(null)
}
private fun handleGetStats(result: MethodChannel.Result) {
activity?.runOnUiThread {
val stats = if (usingMpvFallback) {
// For MPV fallback, query MPV properties directly
getMpvStats()
} else {
if (usingMpvFallback) {
mpvCore?.runOnExecutor {
val stats = getMpvStats()
activity?.runOnUiThread { result.success(stats) }
} ?: result.success(mapOf("playerType" to "mpv"))
} else {
activity?.runOnUiThread {
val coreStats = playerCore?.getStats() ?: emptyMap()
coreStats + mapOf("playerType" to "exoplayer")
}
result.success(stats)
} ?: result.success(mapOf("playerType" to "unknown"))
result.success(coreStats + mapOf("playerType" to "exoplayer"))
} ?: result.success(mapOf("playerType" to "unknown"))
}
}
/**
@@ -451,7 +524,9 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
private fun getMpvStats(): Map<String, Any?> {
val mpv = mpvCore ?: return mapOf("playerType" to "mpv")
return mapOf(
val hasVideo = mpv.getProperty("video-params/w") != null
val stats = mutableMapOf<String, Any?>(
"playerType" to "mpv",
// Video metrics
"video-codec" to mpv.getProperty("video-codec"),
@@ -468,27 +543,32 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
"audio-bitrate" to mpv.getProperty("audio-bitrate"),
// Performance metrics
"total-avsync-change" to mpv.getProperty("total-avsync-change"),
"cache-used" to mpv.getProperty("cache-used"),
"cache-speed" to mpv.getProperty("cache-speed"),
"display-fps" to mpv.getProperty("display-fps"),
"frame-drop-count" to mpv.getProperty("frame-drop-count"),
"decoder-frame-drop-count" to mpv.getProperty("decoder-frame-drop-count"),
"demuxer-cache-duration" to mpv.getProperty("demuxer-cache-duration"),
// Color/Format properties
"video-params/pixelformat" to mpv.getProperty("video-params/pixelformat"),
"video-params/hw-pixelformat" to mpv.getProperty("video-params/hw-pixelformat"),
"video-params/colormatrix" to mpv.getProperty("video-params/colormatrix"),
"video-params/primaries" to mpv.getProperty("video-params/primaries"),
"video-params/gamma" to mpv.getProperty("video-params/gamma"),
// HDR metadata
"video-params/max-luma" to mpv.getProperty("video-params/max-luma"),
"video-params/min-luma" to mpv.getProperty("video-params/min-luma"),
"video-params/max-cll" to mpv.getProperty("video-params/max-cll"),
"video-params/max-fall" to mpv.getProperty("video-params/max-fall"),
// Other
"video-params/aspect-name" to mpv.getProperty("video-params/aspect-name"),
"video-params/rotate" to mpv.getProperty("video-params/rotate")
)
// Only query properties that require an active video track
if (hasVideo) {
stats["display-fps"] = mpv.getProperty("display-fps")
// Color/Format properties
stats["video-params/pixelformat"] = mpv.getProperty("video-params/pixelformat")
stats["video-params/hw-pixelformat"] = mpv.getProperty("video-params/hw-pixelformat")
stats["video-params/colormatrix"] = mpv.getProperty("video-params/colormatrix")
stats["video-params/primaries"] = mpv.getProperty("video-params/primaries")
stats["video-params/gamma"] = mpv.getProperty("video-params/gamma")
// HDR metadata
stats["video-params/max-luma"] = mpv.getProperty("video-params/max-luma")
stats["video-params/min-luma"] = mpv.getProperty("video-params/min-luma")
stats["video-params/max-cll"] = mpv.getProperty("video-params/max-cll")
stats["video-params/max-fall"] = mpv.getProperty("video-params/max-fall")
// Other
stats["video-params/aspect-name"] = mpv.getProperty("video-params/aspect-name")
stats["video-params/rotate"] = mpv.getProperty("video-params/rotate")
}
return stats
}
// PiP Mode handling
@@ -506,13 +586,8 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
// ExoPlayerDelegate
override fun onPropertyChange(name: String, value: Any?) {
eventSink?.success(
mapOf(
"type" to "property",
"name" to name,
"value" to value
)
)
val propId = nameToId[name] ?: return
eventSink?.success(listOf(propId, value))
}
override fun onEvent(name: String, data: Map<String, Any>?) {
@@ -549,71 +624,122 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
positionMs: Long,
errorMessage: String
): Boolean {
if (usingMpvFallback || fallbackInProgress) {
Log.w(TAG, "Fallback already active/in-progress, ignoring duplicate request")
return true
}
val currentActivity = activity ?: return false
fallbackInProgress = true
Log.i(TAG, "ExoPlayer error, switching to MPV fallback at ${positionMs}ms: $errorMessage")
if (debugLoggingEnabled) {
onEvent("log-message", mapOf(
"prefix" to "fallback", "level" to "warn",
"text" to "Switching to MPV at ${positionMs}ms: $errorMessage"
))
}
currentActivity.runOnUiThread {
try {
// Dispose ExoPlayer
playerCore?.dispose()
playerCore = null
mpvCore?.dispose()
mpvCore = null
// Create and initialize MPV
mpvCore = MpvPlayerCore(currentActivity).apply {
delegate = this@ExoPlayerPlugin
}
val success = mpvCore?.initialize() ?: false
mpvCore?.initialize { success ->
if (!success) {
fallbackInProgress = false
Log.e(TAG, "Failed to initialize MPV fallback")
onEvent("end-file", mapOf("reason" to "error", "message" to "Fallback failed: $errorMessage"))
return@initialize
}
if (!success) {
Log.e(TAG, "Failed to initialize MPV fallback")
onEvent("end-file", mapOf("reason" to "error", "message" to "Fallback failed: $errorMessage"))
return@runOnUiThread
usingMpvFallback = true
fallbackInProgress = false
// Snapshot pending properties on main thread before clearing
val pendingProps = pendingMpvProperties.toList()
pendingMpvProperties.clear()
// Compute content FD on main thread (needs contentResolver)
val mpvUri = openContentFd(uri)?.let { "fdclose://$it" } ?: uri
// Buffer size for closure
val bufferSize = configuredBufferSizeBytes
mpvCore?.runOnExecutor {
// Configure basic MPV properties for Plex playback
mpvCore?.setProperty("hwdec", "mediacodec,mediacodec-copy")
mpvCore?.setProperty("vo", "gpu")
mpvCore?.setProperty("ao", "audiotrack")
// Forward user's buffer config to MPV fallback
if (bufferSize != null && bufferSize > 0) {
mpvCore?.setProperty("demuxer-max-bytes", bufferSize.toString())
}
// Apply pending MPV properties from Dart
for ((propName, propValue) in pendingProps) {
mpvCore?.setProperty(propName, propValue)
}
// Setup property observers
mpvCore?.observeProperty("time-pos", "double")
mpvCore?.observeProperty("duration", "double")
mpvCore?.observeProperty("seekable", "flag")
mpvCore?.observeProperty("pause", "flag")
mpvCore?.observeProperty("paused-for-cache", "flag")
mpvCore?.observeProperty("demuxer-cache-time", "double")
mpvCore?.observeProperty("eof-reached", "flag")
mpvCore?.observeProperty("track-list", "string")
mpvCore?.observeProperty("aid", "string")
mpvCore?.observeProperty("sid", "string")
mpvCore?.observeProperty("volume", "double")
mpvCore?.observeProperty("speed", "double")
// Show the MPV surface (internally posts to UI)
mpvCore?.setVisible(true)
// Load media at the same position
val startSeconds = positionMs / 1000.0
val options = mutableListOf<String>()
options.add("start=$startSeconds")
headers?.forEach { (key, value) ->
options.add("http-header-fields-append=$key: $value")
}
val optionsStr = options.joinToString(",")
mpvCore?.command(arrayOf("loadfile", mpvUri, "replace", "-1", optionsStr))
// On GPUs without compute shaders, MPV can't do dynamic peak detection
// and spline tone-mapping produces dim/washed-out results with extreme
// static HDR peak metadata. Use reinhard which handles this better.
val peakDetection = mpvCore?.getProperty("hdr-compute-peak")
if (peakDetection == "no") {
Log.i(TAG, "No compute shaders — overriding tone-mapping to reinhard")
mpvCore?.setProperty("tone-mapping", "reinhard")
mpvCore?.setProperty("tone-mapping-param", "0.7")
mpvCore?.setProperty("tone-mapping-mode", "luma")
}
// Request audio focus
mpvCore?.requestAudioFocus()
// Emit backend-switched event on main thread
activity?.runOnUiThread {
onEvent("backend-switched", null)
}
Log.i(TAG, "Successfully switched to MPV fallback")
}
}
usingMpvFallback = true
// Configure basic MPV properties for Plex playback
mpvCore?.setProperty("hwdec", "auto")
mpvCore?.setProperty("vo", "gpu")
mpvCore?.setProperty("ao", "audiotrack")
// Setup property observers
mpvCore?.observeProperty("time-pos", "double")
mpvCore?.observeProperty("duration", "double")
mpvCore?.observeProperty("pause", "flag")
mpvCore?.observeProperty("paused-for-cache", "flag")
mpvCore?.observeProperty("demuxer-cache-time", "double")
mpvCore?.observeProperty("eof-reached", "flag")
mpvCore?.observeProperty("track-list", "string")
mpvCore?.observeProperty("aid", "string")
mpvCore?.observeProperty("sid", "string")
mpvCore?.observeProperty("volume", "double")
mpvCore?.observeProperty("speed", "double")
// Show the MPV surface
mpvCore?.setVisible(true)
// Load media at the same position
val startSeconds = positionMs / 1000.0
val options = mutableListOf<String>()
options.add("start=$startSeconds")
headers?.forEach { (key, value) ->
options.add("http-header-fields-append=$key: $value")
}
val optionsStr = options.joinToString(",")
// Convert content:// URIs to fdclose:// for MPV (SAF SD card downloads)
val mpvUri = openContentFd(uri)?.let { "fdclose://$it" } ?: uri
mpvCore?.command(arrayOf("loadfile", mpvUri, "replace", "-1", optionsStr))
// Request audio focus
mpvCore?.requestAudioFocus()
// Emit backend-switched event so Flutter can show notification
onEvent("backend-switched", null)
Log.i(TAG, "Successfully switched to MPV fallback")
} catch (e: Exception) {
fallbackInProgress = false
Log.e(TAG, "Failed to switch to MPV fallback", e)
onEvent("end-file", mapOf("reason" to "error", "message" to "Fallback failed: ${e.message}"))
}
@@ -0,0 +1,260 @@
package com.edde746.plezy.exoplayer
import android.content.Context
import android.media.AudioDeviceInfo
import androidx.annotation.OptIn
import androidx.media3.common.PlaybackParameters
import androidx.media3.common.util.Clock
import androidx.media3.common.util.UnstableApi
import androidx.media3.exoplayer.DefaultRenderersFactory
import androidx.media3.exoplayer.analytics.PlayerId
import androidx.media3.exoplayer.audio.AudioOutput
import androidx.media3.exoplayer.audio.AudioOutputProvider
import androidx.media3.exoplayer.audio.AudioSink
import androidx.media3.exoplayer.audio.AudioTrackAudioOutputProvider
import androidx.media3.exoplayer.audio.DefaultAudioSink
import androidx.media3.exoplayer.audio.DefaultAudioTrackBufferSizeProvider
import androidx.media3.exoplayer.audio.ForwardingAudioSink
import java.nio.ByteBuffer
import java.util.concurrent.atomic.AtomicLong
@OptIn(UnstableApi::class)
class PlezyRenderersFactory(context: Context) : DefaultRenderersFactory(context) {
override fun buildAudioSink(
context: Context,
enableFloatOutput: Boolean,
enableAudioOutputPlaybackParams: Boolean
): AudioSink {
AudioTrackAudioOutputProvider.failOnSpuriousAudioTimestamp = false
val bufferSizeProvider = DefaultAudioTrackBufferSizeProvider.Builder()
.setMinPcmBufferDurationUs(500_000)
.setMaxPcmBufferDurationUs(1_500_000)
.setPcmBufferMultiplicationFactor(8)
.build()
val realProvider = AudioTrackAudioOutputProvider.Builder(context)
.setAudioTrackBufferSizeProvider(bufferSizeProvider)
.build()
// Shared position: RawPositionAudioOutput writes the raw AudioTrack position,
// PositionFixAudioSink reads it to bypass DefaultAudioSink's writtenDuration clamp.
val rawPositionUs = AtomicLong(Long.MIN_VALUE)
val defaultSink = DefaultAudioSink.Builder(context)
.setEnableFloatOutput(enableFloatOutput)
.setEnableAudioOutputPlaybackParameters(enableAudioOutputPlaybackParams)
.setAudioOutputProvider(RawPositionOutputProvider(realProvider, rawPositionUs))
.build()
return PositionFixAudioSink(defaultSink, rawPositionUs)
}
}
/**
* Fixes video stutter with large audio frames (e.g. 120ms Opus).
*
* DefaultAudioSink.getCurrentPositionUs() clamps the playback position to
* writtenDuration via Math.min(positionUs, framesToDurationUs(writtenFrames)).
* With large audio frames, data arrives in bursts and writtenDuration lags behind
* the real AudioTrack playback position between bursts, creating a sawtooth
* position pattern (plateau → jump) that makes the video renderer drop frames.
*
* Fix: when DefaultAudioSink's position falls behind the raw AudioTrack position,
* return startMediaTimeUs + rawPosition instead, giving the video renderer a
* smooth clock to sync against.
*
* Also suppresses Amlogic AudioTrack timestamp discontinuity errors.
*
* The raw AudioTrack position advances at real-time rate regardless of speed
* (AudioTrackPositionTracker reports post-time-stretch output frames). The
* bypass multiplies by speed to convert to media time, matching what
* DefaultAudioSink.applyMediaPositionParameters() does internally. Reference
* points are captured on speed changes for correct mid-playback transitions.
*/
@OptIn(UnstableApi::class)
private class PositionFixAudioSink(
sink: AudioSink,
private val rawPositionUs: AtomicLong
) : ForwardingAudioSink(sink) {
private var startMediaTimeUs = Long.MIN_VALUE
private var suppressedErrorCount = 0
// Speed tracking for position bypass
private var currentSpeed = 1.0f
private var refMediaTimeUs = Long.MIN_VALUE
private var refRawPositionUs = 0L
override fun handleBuffer(
buffer: ByteBuffer,
presentationTimeUs: Long,
encodedAccessUnitCount: Int
): Boolean {
if (startMediaTimeUs == Long.MIN_VALUE) {
startMediaTimeUs = presentationTimeUs
refMediaTimeUs = presentationTimeUs
refRawPositionUs = 0
}
return super.handleBuffer(buffer, presentationTimeUs, encodedAccessUnitCount)
}
override fun setPlaybackParameters(playbackParameters: PlaybackParameters) {
// Capture reference point before speed changes
val rawPos = rawPositionUs.get()
if (rawPos > 0 && refMediaTimeUs != Long.MIN_VALUE) {
refMediaTimeUs = refMediaTimeUs + ((rawPos - refRawPositionUs) * currentSpeed).toLong()
refRawPositionUs = rawPos
}
currentSpeed = playbackParameters.speed
super.setPlaybackParameters(playbackParameters)
}
override fun getCurrentPositionUs(sourceEnded: Boolean): Long {
val delegatePos = super.getCurrentPositionUs(sourceEnded)
if (delegatePos == Long.MIN_VALUE || refMediaTimeUs == Long.MIN_VALUE) {
return delegatePos
}
val rawPos = rawPositionUs.get()
if (rawPos <= 0) return delegatePos
val expectedPos = refMediaTimeUs + ((rawPos - refRawPositionUs) * currentSpeed).toLong()
return if (expectedPos > delegatePos + 30_000) expectedPos else delegatePos
}
// --- Suppress timestamp discontinuity errors ---
override fun setListener(listener: AudioSink.Listener) {
super.setListener(@OptIn(UnstableApi::class) object : AudioSink.Listener {
override fun onPositionDiscontinuity() = listener.onPositionDiscontinuity()
override fun onPositionAdvancing(playoutStartSystemTimeUs: Long) = listener.onPositionAdvancing(playoutStartSystemTimeUs)
override fun onUnderrun(bufferSize: Int, bufferSizeMs: Long, elapsedSinceLastFeedMs: Long) = listener.onUnderrun(bufferSize, bufferSizeMs, elapsedSinceLastFeedMs)
override fun onSkipSilenceEnabledChanged(skipSilenceEnabled: Boolean) = listener.onSkipSilenceEnabledChanged(skipSilenceEnabled)
override fun onOffloadBufferEmptying() = listener.onOffloadBufferEmptying()
override fun onOffloadBufferFull() = listener.onOffloadBufferFull()
override fun onAudioCapabilitiesChanged() = listener.onAudioCapabilitiesChanged()
override fun onAudioTrackInitialized(audioTrackConfig: AudioSink.AudioTrackConfig) = listener.onAudioTrackInitialized(audioTrackConfig)
override fun onAudioTrackReleased(audioTrackConfig: AudioSink.AudioTrackConfig) = listener.onAudioTrackReleased(audioTrackConfig)
override fun onSilenceSkipped() = listener.onSilenceSkipped()
override fun onAudioSessionIdChanged(audioSessionId: Int) = listener.onAudioSessionIdChanged(audioSessionId)
override fun onAudioSinkError(audioSinkError: Exception) {
if (isTimestampDiscontinuity(audioSinkError)) {
suppressedErrorCount++
return
}
listener.onAudioSinkError(audioSinkError)
}
})
}
override fun flush() {
startMediaTimeUs = Long.MIN_VALUE
refMediaTimeUs = Long.MIN_VALUE
refRawPositionUs = 0
rawPositionUs.set(Long.MIN_VALUE)
super.flush()
}
override fun reset() {
startMediaTimeUs = Long.MIN_VALUE
refMediaTimeUs = Long.MIN_VALUE
refRawPositionUs = 0
currentSpeed = 1.0f
rawPositionUs.set(Long.MIN_VALUE)
suppressedErrorCount = 0
super.reset()
}
private fun isTimestampDiscontinuity(e: Exception): Boolean {
val name = e.javaClass.simpleName
val msg = e.message ?: ""
return name == "InvalidAudioTrackTimestampException" ||
name == "UnexpectedDiscontinuityException" ||
msg.contains("timestamp discontinuity", ignoreCase = true)
}
}
// --- AudioOutput wrapping: shares raw position with PositionFixAudioSink ---
@OptIn(UnstableApi::class)
private class RawPositionOutputProvider(
private val delegate: AudioOutputProvider,
private val rawPositionUs: AtomicLong
) : AudioOutputProvider {
override fun getFormatSupport(config: AudioOutputProvider.FormatConfig) =
delegate.getFormatSupport(config)
override fun getOutputConfig(config: AudioOutputProvider.FormatConfig) =
delegate.getOutputConfig(config)
override fun getAudioOutput(config: AudioOutputProvider.OutputConfig): AudioOutput {
val realOutput = delegate.getAudioOutput(config)
return RawPositionAudioOutput(realOutput, rawPositionUs)
}
override fun addListener(listener: AudioOutputProvider.Listener) =
delegate.addListener(listener)
override fun removeListener(listener: AudioOutputProvider.Listener) =
delegate.removeListener(listener)
override fun setClock(clock: Clock) = delegate.setClock(clock)
override fun release() = delegate.release()
}
@OptIn(UnstableApi::class)
private class RawPositionAudioOutput(
private val delegate: AudioOutput,
private val rawPositionUs: AtomicLong
) : AudioOutput {
override fun getPositionUs(): Long {
val pos = delegate.getPositionUs()
rawPositionUs.set(pos)
return pos
}
override fun play() = delegate.play()
override fun pause() = delegate.pause()
@Throws(AudioOutput.WriteException::class)
override fun write(buffer: ByteBuffer, size: Int, presentationTimeUs: Long) =
delegate.write(buffer, size, presentationTimeUs)
override fun flush() {
rawPositionUs.set(Long.MIN_VALUE)
delegate.flush()
}
override fun stop() = delegate.stop()
override fun release() {
rawPositionUs.set(Long.MIN_VALUE)
delegate.release()
}
override fun setVolume(volume: Float) = delegate.setVolume(volume)
override fun isOffloadedPlayback() = delegate.isOffloadedPlayback()
override fun getAudioSessionId() = delegate.getAudioSessionId()
override fun getSampleRate() = delegate.getSampleRate()
override fun getBufferSizeInFrames() = delegate.getBufferSizeInFrames()
override fun getPlaybackParameters() = delegate.getPlaybackParameters()
override fun isStalled() = delegate.isStalled()
override fun addListener(listener: AudioOutput.Listener) = delegate.addListener(listener)
override fun removeListener(listener: AudioOutput.Listener) = delegate.removeListener(listener)
override fun setPlaybackParameters(playbackParameters: PlaybackParameters) =
delegate.setPlaybackParameters(playbackParameters)
override fun setOffloadDelayPadding(delayInFrames: Int, paddingInFrames: Int) =
delegate.setOffloadDelayPadding(delayInFrames, paddingInFrames)
override fun setOffloadEndOfStream() = delegate.setOffloadEndOfStream()
override fun setPlayerId(playerId: PlayerId) = delegate.setPlayerId(playerId)
override fun attachAuxEffect(effectId: Int) = delegate.attachAuxEffect(effectId)
override fun setAuxEffectSendLevel(level: Float) = delegate.setAuxEffectSendLevel(level)
override fun setPreferredDevice(preferredDevice: AudioDeviceInfo?) =
delegate.setPreferredDevice(preferredDevice)
}
File diff suppressed because it is too large Load Diff
@@ -11,7 +11,7 @@ import io.flutter.plugin.common.MethodCall
import io.flutter.plugin.common.MethodChannel
class MpvPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
EventChannel.StreamHandler, ActivityAware, MpvPlayerDelegate {
EventChannel.StreamHandler, ActivityAware, com.edde746.plezy.shared.PlayerDelegate {
companion object {
private const val TAG = "MpvPlayerPlugin"
@@ -25,6 +25,7 @@ class MpvPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
private var playerCore: MpvPlayerCore? = null
private var activity: Activity? = null
private var activityBinding: ActivityPluginBinding? = null
private val nameToId = mutableMapOf<String, Int>()
// FlutterPlugin
@@ -101,6 +102,7 @@ class MpvPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
"abandonAudioFocus" -> handleAbandonAudioFocus(result)
"openContentFd" -> handleOpenContentFd(call, result)
"isInitialized" -> result.success(playerCore?.isInitialized ?: false)
"setLogLevel" -> result.success(null)
else -> result.notImplemented()
}
}
@@ -123,14 +125,14 @@ class MpvPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
playerCore = MpvPlayerCore(currentActivity).apply {
delegate = this@MpvPlayerPlugin
}
val success = playerCore?.initialize() ?: false
// Start hidden - now safe because setVisible operates on the container,
// not the SurfaceView directly (matching ExoPlayer's approach)
playerCore?.setVisible(false)
Log.d(TAG, "Initialized: $success")
result.success(success)
playerCore?.initialize { success ->
// Start hidden - now safe because setVisible operates on the container,
// not the SurfaceView directly (matching ExoPlayer's approach)
playerCore?.setVisible(false)
Log.d(TAG, "Initialized: $success")
result.success(success)
} ?: result.success(false)
} catch (e: Exception) {
Log.e(TAG, "Failed to initialize: ${e.message}", e)
result.error("INIT_FAILED", e.message, null)
@@ -140,10 +142,14 @@ class MpvPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
private fun handleDispose(result: MethodChannel.Result) {
activity?.runOnUiThread {
playerCore?.dispose()
playerCore = null
Log.d(TAG, "Disposed")
result.success(null)
playerCore?.dispose {
playerCore = null
Log.d(TAG, "Disposed")
result.success(null)
} ?: run {
playerCore = null
result.success(null)
}
} ?: result.success(null)
}
@@ -156,8 +162,8 @@ class MpvPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
return
}
playerCore?.setProperty(name, value)
result.success(null)
playerCore?.setPropertyAsync(name, value, result)
?: result.success(null)
}
private fun handleGetProperty(call: MethodCall, result: MethodChannel.Result) {
@@ -168,21 +174,23 @@ class MpvPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
return
}
val value = playerCore?.getProperty(name)
result.success(value)
playerCore?.getPropertyAsync(name, result)
?: result.success(null)
}
private fun handleObserveProperty(call: MethodCall, result: MethodChannel.Result) {
val name = call.argument<String>("name")
val format = call.argument<String>("format")
val id = call.argument<Int>("id")
if (name == null || format == null) {
result.error("INVALID_ARGS", "Missing 'name' or 'format'", null)
if (name == null || format == null || id == null) {
result.error("INVALID_ARGS", "Missing 'name', 'format', or 'id'", null)
return
}
playerCore?.observeProperty(name, format)
result.success(null)
nameToId[name] = id
playerCore?.observePropertyAsync(name, format, result)
?: result.success(null)
}
private fun handleCommand(call: MethodCall, result: MethodChannel.Result) {
@@ -245,40 +253,39 @@ class MpvPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
return
}
try {
val uri = Uri.parse(uriString)
val contentResolver = activity?.contentResolver
if (contentResolver == null) {
result.error("NO_ACTIVITY", "Activity not available", null)
return
}
val pfd = contentResolver.openFileDescriptor(uri, "r")
if (pfd == null) {
result.error("OPEN_FAILED", "Failed to open file descriptor for $uriString", null)
return
}
// detachFd() transfers ownership of the FD to the caller (MPV via fdclose://)
val fd = pfd.detachFd()
Log.d(TAG, "Opened content FD $fd for $uriString")
result.success(fd)
} catch (e: Exception) {
Log.e(TAG, "Failed to open content FD: ${e.message}", e)
result.error("OPEN_FAILED", e.message, null)
val contentResolver = activity?.contentResolver
if (contentResolver == null) {
result.error("NO_ACTIVITY", "Activity not available", null)
return
}
// Open file descriptor off UI thread to prevent ANR on slow storage
playerCore?.runOnExecutor {
try {
val uri = Uri.parse(uriString)
val pfd = contentResolver.openFileDescriptor(uri, "r")
if (pfd == null) {
activity?.runOnUiThread {
result.error("OPEN_FAILED", "Failed to open file descriptor for $uriString", null)
}
return@runOnExecutor
}
val fd = pfd.detachFd()
Log.d(TAG, "Opened content FD $fd for $uriString")
activity?.runOnUiThread { result.success(fd) }
} catch (e: Exception) {
Log.e(TAG, "Failed to open content FD: ${e.message}", e)
activity?.runOnUiThread { result.error("OPEN_FAILED", e.message, null) }
}
} ?: result.error("NO_PLAYER", "Player not initialized", null)
}
// MpvPlayerDelegate
// PlayerDelegate
override fun onPropertyChange(name: String, value: Any?) {
eventSink?.success(
mapOf(
"type" to "property",
"name" to name,
"value" to value
)
)
val propId = nameToId[name] ?: return
eventSink?.success(listOf(propId, value))
}
override fun onEvent(name: String, data: Map<String, Any>?) {
@@ -0,0 +1,105 @@
package com.edde746.plezy.shared
import android.content.Context
import android.media.AudioAttributes
import android.media.AudioFocusRequest
import android.media.AudioManager
import android.os.Build
import android.os.Handler
import android.util.Log
class AudioFocusManager(
context: Context,
private val handler: Handler,
private val onPause: () -> Unit,
private val onResume: () -> Unit,
private val isPaused: () -> Boolean,
private val log: (String) -> Unit = { Log.d(TAG, it) }
) {
companion object {
private const val TAG = "AudioFocusManager"
}
private val audioManager = context.getSystemService(Context.AUDIO_SERVICE) as AudioManager
private var audioFocusRequest: AudioFocusRequest? = null
private var hasAudioFocus: Boolean = false
var wasPlayingBeforeFocusLoss: Boolean = false
private set
private val audioFocusChangeListener = AudioManager.OnAudioFocusChangeListener { focusChange ->
when (focusChange) {
AudioManager.AUDIOFOCUS_GAIN -> {
log("Focus gained")
hasAudioFocus = true
if (wasPlayingBeforeFocusLoss) {
onResume()
wasPlayingBeforeFocusLoss = false
}
}
AudioManager.AUDIOFOCUS_LOSS -> {
log("Focus lost permanently")
hasAudioFocus = false
wasPlayingBeforeFocusLoss = !isPaused()
onPause()
}
AudioManager.AUDIOFOCUS_LOSS_TRANSIENT -> {
log("Focus lost transiently")
hasAudioFocus = false
wasPlayingBeforeFocusLoss = !isPaused()
onPause()
}
AudioManager.AUDIOFOCUS_LOSS_TRANSIENT_CAN_DUCK -> {
log("Focus lost transiently (can duck)")
}
}
}
fun requestAudioFocus(): Boolean {
Log.d(TAG, "Requesting audio focus")
val result = if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
val focusRequest = AudioFocusRequest.Builder(AudioManager.AUDIOFOCUS_GAIN)
.setAudioAttributes(
AudioAttributes.Builder()
.setUsage(AudioAttributes.USAGE_MEDIA)
.setContentType(AudioAttributes.CONTENT_TYPE_MOVIE)
.build()
)
.setOnAudioFocusChangeListener(audioFocusChangeListener, handler)
.build()
audioFocusRequest = focusRequest
audioManager.requestAudioFocus(focusRequest)
} else {
@Suppress("DEPRECATION")
audioManager.requestAudioFocus(
audioFocusChangeListener,
AudioManager.STREAM_MUSIC,
AudioManager.AUDIOFOCUS_GAIN
)
}
hasAudioFocus = (result == AudioManager.AUDIOFOCUS_REQUEST_GRANTED)
Log.d(TAG, "Audio focus request result: $result, granted: $hasAudioFocus")
return hasAudioFocus
}
fun abandonAudioFocus() {
Log.d(TAG, "Abandoning audio focus")
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
audioFocusRequest?.let { audioManager.abandonAudioFocusRequest(it) }
audioFocusRequest = null
} else {
@Suppress("DEPRECATION")
audioManager.abandonAudioFocus(audioFocusChangeListener)
}
hasAudioFocus = false
wasPlayingBeforeFocusLoss = false
}
fun release() {
abandonAudioFocus()
}
}
@@ -0,0 +1,59 @@
package com.edde746.plezy.shared
import android.graphics.PixelFormat
import android.view.SurfaceView
import android.view.TextureView
import android.view.View
import android.view.ViewGroup
object FlutterOverlayHelper {
/**
* Find the FlutterView container in the content view hierarchy.
* First tries to match by class name (works in debug builds),
* then falls back to picking the last ViewGroup with children
* (needed for release builds where FlutterView may be obfuscated).
*/
fun findFlutterContainer(contentView: ViewGroup, excludeView: View? = null): ViewGroup? {
// First pass: look for FlutterView by name (debug builds)
for (i in 0 until contentView.childCount) {
val child = contentView.getChildAt(i)
if (child is ViewGroup && child.javaClass.name.contains("FlutterView")) {
return child
}
}
// Fallback for release (FlutterView may be obfuscated): pick the last ViewGroup
// that is not our video container and has children.
for (i in contentView.childCount - 1 downTo 0) {
val child = contentView.getChildAt(i)
if (child is ViewGroup && child != excludeView && child.childCount > 0) {
return child
}
}
return null
}
/**
* Configure z-ordering so the Flutter UI renders above the video surface.
*
* @param zOrderOnTop true for MPV (Flutter needs to be fully on top),
* false for ExoPlayer (subtitle layer sits between video and Flutter)
*/
fun configureFlutterZOrder(contentView: ViewGroup, container: ViewGroup, zOrderOnTop: Boolean) {
contentView.bringChildToFront(container)
for (j in 0 until container.childCount) {
val flutterChild = container.getChildAt(j)
if (flutterChild is SurfaceView) {
flutterChild.setZOrderOnTop(zOrderOnTop)
flutterChild.setZOrderMediaOverlay(true)
flutterChild.holder.setFormat(PixelFormat.TRANSLUCENT)
break
} else if (flutterChild is TextureView) {
flutterChild.isOpaque = false
break
}
}
}
}
@@ -0,0 +1,181 @@
package com.edde746.plezy.shared
import android.app.Activity
import android.content.Context
import android.hardware.display.DisplayManager
import android.os.Build
import android.os.Handler
import android.util.Log
import android.view.Surface
import android.view.WindowManager
import androidx.annotation.RequiresApi
import java.math.BigDecimal
import java.math.RoundingMode
class FrameRateManager(
private val activity: Activity,
private val handler: Handler,
private val onDisplayChanged: () -> Unit,
private val log: (String) -> Unit = { Log.d(TAG, it) }
) {
companion object {
private const val TAG = "FrameRateManager"
private const val SHORT_VIDEO_LENGTH_MS = 300000L // 5 minutes
}
private var currentVideoFps: Float = 0f
private var displayListener: DisplayManager.DisplayListener? = null
private fun getDisplayManager(): DisplayManager {
return activity.getSystemService(Context.DISPLAY_SERVICE) as DisplayManager
}
fun setVideoFrameRate(fps: Float, videoDurationMs: Long, surface: Surface?) {
currentVideoFps = fps
if (fps <= 0f) {
Log.d(TAG, "setVideoFrameRate: Invalid fps ($fps), skipping")
return
}
if (surface == null) {
Log.d(TAG, "setVideoFrameRate: Surface not available")
return
}
log("fps=$fps, duration=${videoDurationMs}ms, API=${Build.VERSION.SDK_INT}")
when {
Build.VERSION.SDK_INT >= Build.VERSION_CODES.S -> setFrameRateS(fps, surface, videoDurationMs)
Build.VERSION.SDK_INT >= Build.VERSION_CODES.R -> setFrameRateR(fps, surface)
Build.VERSION.SDK_INT >= Build.VERSION_CODES.M -> setFrameRateM(fps)
}
}
fun clearVideoFrameRate() {
Log.d(TAG, "clearVideoFrameRate")
currentVideoFps = 0f
displayListener?.let {
getDisplayManager().unregisterDisplayListener(it)
displayListener = null
}
}
private fun registerDisplayListener() {
displayListener?.let {
getDisplayManager().unregisterDisplayListener(it)
}
displayListener = object : DisplayManager.DisplayListener {
override fun onDisplayAdded(displayId: Int) = Unit
override fun onDisplayRemoved(displayId: Int) = Unit
override fun onDisplayChanged(displayId: Int) {
handler.postDelayed({
onDisplayChanged()
}, 2000L)
getDisplayManager().unregisterDisplayListener(this)
displayListener = null
}
}
getDisplayManager().registerDisplayListener(displayListener, handler)
}
@RequiresApi(Build.VERSION_CODES.R)
private fun setFrameRateR(fps: Float, surface: Surface) {
Log.d(TAG, "setFrameRateR: Setting frame rate to $fps")
surface.setFrameRate(fps, Surface.FRAME_RATE_COMPATIBILITY_FIXED_SOURCE)
registerDisplayListener()
}
@RequiresApi(Build.VERSION_CODES.S)
private fun setFrameRateS(fps: Float, surface: Surface, videoDurationMs: Long) {
Log.d(TAG, "setFrameRateS: fps=$fps, duration=${videoDurationMs}ms")
if (videoDurationMs < SHORT_VIDEO_LENGTH_MS) {
Log.d(TAG, "Short video, using seamless-only switching")
surface.setFrameRate(
fps,
Surface.FRAME_RATE_COMPATIBILITY_FIXED_SOURCE,
Surface.CHANGE_FRAME_RATE_ONLY_IF_SEAMLESS
)
return
}
var seamless = false
activity.display?.mode?.alternativeRefreshRates?.let { refreshRates ->
for (rate in refreshRates) {
if (fps.toString().startsWith(rate.toString()) ||
rate.toString().startsWith(fps.toString()) ||
rate % fps == 0f) {
seamless = true
break
}
}
}
if (seamless) {
log("Seamless switch available for ${fps}fps")
surface.setFrameRate(
fps,
Surface.FRAME_RATE_COMPATIBILITY_FIXED_SOURCE,
Surface.CHANGE_FRAME_RATE_ALWAYS
)
registerDisplayListener()
} else {
val userPreference = getDisplayManager().matchContentFrameRateUserPreference
if (userPreference == DisplayManager.MATCH_CONTENT_FRAMERATE_ALWAYS) {
Log.d(TAG, "User preference allows non-seamless switch")
surface.setFrameRate(
fps,
Surface.FRAME_RATE_COMPATIBILITY_FIXED_SOURCE,
Surface.CHANGE_FRAME_RATE_ALWAYS
)
registerDisplayListener()
} else {
Log.d(TAG, "Non-seamless switch not allowed, using seamless-only")
surface.setFrameRate(
fps,
Surface.FRAME_RATE_COMPATIBILITY_FIXED_SOURCE,
Surface.CHANGE_FRAME_RATE_ONLY_IF_SEAMLESS
)
}
}
}
@RequiresApi(Build.VERSION_CODES.M)
private fun setFrameRateM(fps: Float) {
Log.d(TAG, "setFrameRateM: fps=$fps")
val wm = activity.getSystemService(Context.WINDOW_SERVICE) as WindowManager
@Suppress("DEPRECATION")
val display = wm.defaultDisplay ?: return
display.supportedModes?.let { supportedModes ->
val currentMode = display.mode
var modeToUse = currentMode
for (mode in supportedModes) {
if (mode.physicalHeight != currentMode.physicalHeight ||
mode.physicalWidth != currentMode.physicalWidth) {
continue
}
if (BigDecimal(fps.toString()).setScale(1, RoundingMode.FLOOR) ==
BigDecimal(mode.refreshRate.toString()).setScale(1, RoundingMode.FLOOR)) {
modeToUse = mode
break
} else if (mode.refreshRate % fps == 0f) {
modeToUse = mode
break
}
}
if (modeToUse != currentMode) {
Log.d(TAG, "Switching to mode ${modeToUse.modeId} (${modeToUse.refreshRate}Hz)")
activity.window?.attributes?.let { attrs ->
attrs.preferredDisplayModeId = modeToUse.modeId
activity.window?.attributes = attrs
}
registerDisplayListener()
}
}
}
}
@@ -0,0 +1,6 @@
package com.edde746.plezy.shared
interface PlayerDelegate {
fun onPropertyChange(name: String, value: Any?)
fun onEvent(name: String, data: Map<String, Any>?)
}
@@ -0,0 +1,12 @@
package com.edde746.plezy.shared
import android.graphics.Color
object ThemeHelper {
fun themeColor(mode: String?): Int? = when (mode) {
"oled" -> Color.BLACK
"dark" -> Color.parseColor("#0E0F12")
"light" -> Color.parseColor("#F7F7F8")
else -> null
}
}
@@ -3,11 +3,14 @@ package com.edde746.plezy.watchnext
import android.content.Context
import android.content.Intent
import android.content.pm.PackageManager
import android.os.Handler
import android.os.Looper
import android.util.Log
import androidx.tvprovider.media.tv.TvContractCompat
import io.flutter.embedding.engine.plugins.FlutterPlugin
import io.flutter.plugin.common.MethodCall
import io.flutter.plugin.common.MethodChannel
import java.util.concurrent.Executors
/**
* Flutter plugin for Android TV Watch Next integration.
@@ -17,7 +20,7 @@ class WatchNextPlugin : FlutterPlugin, MethodChannel.MethodCallHandler {
companion object {
private const val TAG = "WatchNextPlugin"
private const val METHOD_CHANNEL = "app.plezy/watch_next"
private const val METHOD_CHANNEL = "com.plezy/watch_next"
private var pendingDeepLink: String? = null
@@ -37,6 +40,8 @@ class WatchNextPlugin : FlutterPlugin, MethodChannel.MethodCallHandler {
private lateinit var methodChannel: MethodChannel
private var applicationContext: Context? = null
private var watchNextProvider: WatchNextProvider? = null
private val ioExecutor by lazy { Executors.newSingleThreadExecutor() }
private val mainHandler = Handler(Looper.getMainLooper())
override fun onAttachedToEngine(binding: FlutterPlugin.FlutterPluginBinding) {
applicationContext = binding.applicationContext
@@ -49,6 +54,7 @@ class WatchNextPlugin : FlutterPlugin, MethodChannel.MethodCallHandler {
methodChannel.setMethodCallHandler(null)
applicationContext = null
watchNextProvider = null
ioExecutor.shutdown()
}
override fun onMethodCall(call: MethodCall, result: MethodChannel.Result) {
@@ -85,7 +91,7 @@ class WatchNextPlugin : FlutterPlugin, MethodChannel.MethodCallHandler {
}
val items = itemsData.mapNotNull { parseWatchNextItem(it) }
result.success(provider.syncWatchNextPrograms(items))
executeOnIo(result) { provider.syncWatchNextPrograms(items) }
}
private fun handleClear(result: MethodChannel.Result) {
@@ -94,7 +100,7 @@ class WatchNextPlugin : FlutterPlugin, MethodChannel.MethodCallHandler {
result.error("NOT_INITIALIZED", "WatchNextProvider not initialized", null)
return
}
result.success(provider.clearAll())
executeOnIo(result) { provider.clearAll() }
}
private fun handleRemove(call: MethodCall, result: MethodChannel.Result) {
@@ -109,7 +115,23 @@ class WatchNextPlugin : FlutterPlugin, MethodChannel.MethodCallHandler {
result.error("INVALID_ARGS", "Missing 'contentId' argument", null)
return
}
result.success(provider.removeItem(contentId))
executeOnIo(result) { provider.removeItem(contentId) }
}
private fun executeOnIo(result: MethodChannel.Result, block: () -> Any?) {
try {
ioExecutor.execute {
try {
val value = block()
mainHandler.post { result.success(value) }
} catch (e: Exception) {
Log.e(TAG, "IO operation failed: ${e.message}", e)
mainHandler.post { result.error("IO_ERROR", e.message, null) }
}
}
} catch (e: java.util.concurrent.RejectedExecutionException) {
result.error("SHUTDOWN", "Plugin is shutting down", null)
}
}
private fun handleGetInitialDeepLink(result: MethodChannel.Result) {
Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<vector xmlns:aapt="http://schemas.android.com/aapt"
xmlns:android="http://schemas.android.com/apk/res/android"
android:height="108dp"
android:width="108dp"
android:viewportHeight="911.63"
android:viewportWidth="911.63">
<group android:translateX="276.65" android:translateY="223.88">
<path android:pathData="M335.65,192.66L68.01,38.14C37.78,20.69,0,42.5,0,77.41v309.04c0,34.91,37.78,56.72,68.01,39.27l267.64-154.52c30.23-17.45,30.23-61.08,0-78.54ZM255.53,276.8c-19.1,17.66-38.75,26.49-58.4,26.49s-39.29-8.83-58.39-26.49c-14.39-13.3-28.55-20.05-42.11-20.05s-27.72,6.75-42.1,20.05c-4.87,4.5-12.46,4.2-16.96-0.67-4.5-4.86-4.2-12.45 0.67-16.95,38.2-35.33,78.59-35.33,116.79,0,14.38,13.3,28.55,20.04,42.1,20.04s27.72-6.74,42.11-20.04c4.86-4.5,12.46-4.21,16.95,0.66,4.5,4.87,4.21,12.46-0.66,16.96ZM255.53,204.04c-19.1,17.67-38.75,26.5-58.4,26.5s-39.29-8.83-58.39-26.5c-14.39-13.3-28.55-20.04-42.11-20.04s-27.72,6.74-42.1,20.04c-4.87,4.5-12.46,4.21-16.96-0.66s-4.2-12.46,0.67-16.96c38.2-35.32,78.59-35.32,116.79,0,14.38,13.3,28.55,20.05,42.1,20.05s27.72-6.75,42.11-20.05c4.86-4.5,12.46-4.2,16.95,0.67,4.5,4.86,4.21,12.45-0.66,16.95Z">
<aapt:attr name="android:fillColor">
<gradient
android:type="linear"
android:startX="22.67"
android:startY="425.72"
android:endX="201.83"
android:endY="115.4">
<item android:color="#FFAB543A" android:offset="0.0" />
<item android:color="#FFFF7E57" android:offset="1.0" />
</gradient>
</aapt:attr>
</path>
</group>
</vector>
@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:height="108dp"
android:width="108dp"
android:viewportHeight="911.63"
android:viewportWidth="911.63">
<group android:translateX="276.65" android:translateY="223.88">
<path
android:fillColor="#FFFFFFFF"
android:pathData="M335.65,192.66L68.01,38.14C37.78,20.69,0,42.5,0,77.41v309.04c0,34.91,37.78,56.72,68.01,39.27l267.64-154.52c30.23-17.45,30.23-61.08,0-78.54ZM255.53,276.8c-19.1,17.66-38.75,26.49-58.4,26.49s-39.29-8.83-58.39-26.49c-14.39-13.3-28.55-20.05-42.11-20.05s-27.72,6.75-42.1,20.05c-4.87,4.5-12.46,4.2-16.96-0.67-4.5-4.86-4.2-12.45 0.67-16.95,38.2-35.33,78.59-35.33,116.79,0,14.38,13.3,28.55,20.04,42.1,20.04s27.72-6.74,42.11-20.04c4.86-4.5,12.46-4.21,16.95,0.66,4.5,4.87,4.21,12.46-0.66,16.96ZM255.53,204.04c-19.1,17.67-38.75,26.5-58.4,26.5s-39.29-8.83-58.39-26.5c-14.39-13.3-28.55-20.04-42.11-20.04s-27.72,6.74-42.1,20.04c-4.87,4.5-12.46,4.21-16.96-0.66s-4.2-12.46,0.67-16.96c38.2-35.32,78.59-35.32,116.79,0,14.38,13.3,28.55,20.05,42.1,20.05s27.72-6.75,42.11-20.05c4.86-4.5,12.46-4.2,16.95,0.67,4.5,4.86,4.21,12.45-0.66,16.95Z" />
</group>
</vector>
@@ -0,0 +1,3 @@
<?xml version="1.0" encoding="utf-8"?>
<inset xmlns:android="http://schemas.android.com/apk/res/android"
android:drawable="@drawable/ic_launcher_foreground" />
@@ -1,14 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@color/ic_launcher_background"/>
<foreground>
<inset
android:drawable="@drawable/ic_launcher_foreground"
android:inset="16%" />
</foreground>
<monochrome>
<inset
android:drawable="@mipmap/ic_launcher_monochrome"
android:inset="16%" />
</monochrome>
<foreground android:drawable="@drawable/ic_launcher_foreground" />
<monochrome android:drawable="@drawable/ic_launcher_monochrome" />
</adaptive-icon>
Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.1 KiB

@@ -0,0 +1,39 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<style name="LaunchTheme" parent="@android:style/Theme.Black.NoTitleBar">
<item name="android:windowBackground">@color/splash_background</item>
<item name="android:windowSplashScreenAnimatedIcon">@drawable/splash_icon</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
<style name="NormalTheme" parent="@android:style/Theme.Black.NoTitleBar">
<item name="android:windowBackground">@color/splash_background</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
<style name="SplashTheme.Dark" parent="@android:style/Theme.Black.NoTitleBar">
<item name="android:windowBackground">@color/splash_dark</item>
<item name="android:windowSplashScreenAnimatedIcon">@drawable/splash_icon</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
<style name="SplashTheme.Oled" parent="@android:style/Theme.Black.NoTitleBar">
<item name="android:windowBackground">@color/splash_oled</item>
<item name="android:windowSplashScreenAnimatedIcon">@drawable/splash_icon</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
<style name="SplashTheme.Light" parent="@android:style/Theme.Black.NoTitleBar">
<item name="android:windowBackground">@color/splash_light</item>
<item name="android:windowSplashScreenAnimatedIcon">@drawable/splash_icon</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
<style name="SplashTheme.System" parent="@android:style/Theme.Black.NoTitleBar">
<item name="android:windowBackground">@color/splash_background</item>
<item name="android:windowSplashScreenAnimatedIcon">@drawable/splash_icon</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
</resources>
@@ -1,4 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="ic_launcher_background">#1a1a1a</color>
<color name="splash_background">#0E0F12</color>
<color name="splash_dark">#0E0F12</color>
<color name="splash_oled">#000000</color>
<color name="splash_light">#F7F7F8</color>
</resources>
@@ -2,6 +2,7 @@
<resources>
<!-- Theme applied to the Android Window while the process is starting when the OS's Dark Mode setting is on -->
<style name="LaunchTheme" parent="@android:style/Theme.Black.NoTitleBar">
<item name="android:windowBackground">@color/splash_background</item>
<!-- Disable Android's default green focus highlight that appears during d-pad/keyboard navigation -->
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
@@ -13,9 +14,31 @@
This Theme is only used starting with V2 of Flutter's Android embedding. -->
<style name="NormalTheme" parent="@android:style/Theme.Black.NoTitleBar">
<item name="android:windowBackground">@android:color/black</item>
<item name="android:windowBackground">@color/splash_background</item>
<!-- Disable Android's default green focus highlight that appears during d-pad/keyboard navigation -->
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
<!-- Splash theme variants for setSplashScreenTheme -->
<style name="SplashTheme.Dark" parent="@android:style/Theme.Black.NoTitleBar">
<item name="android:windowBackground">@color/splash_dark</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
<style name="SplashTheme.Oled" parent="@android:style/Theme.Black.NoTitleBar">
<item name="android:windowBackground">@color/splash_oled</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
<style name="SplashTheme.Light" parent="@android:style/Theme.Black.NoTitleBar">
<item name="android:windowBackground">@color/splash_light</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
<style name="SplashTheme.System" parent="@android:style/Theme.Black.NoTitleBar">
<item name="android:windowBackground">@color/splash_background</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
</resources>
@@ -0,0 +1,39 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<style name="LaunchTheme" parent="@android:style/Theme.Light.NoTitleBar">
<item name="android:windowBackground">@color/splash_background</item>
<item name="android:windowSplashScreenAnimatedIcon">@drawable/splash_icon</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
<style name="NormalTheme" parent="@android:style/Theme.Light.NoTitleBar">
<item name="android:windowBackground">@color/splash_background</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
<style name="SplashTheme.Dark" parent="@android:style/Theme.Light.NoTitleBar">
<item name="android:windowBackground">@color/splash_dark</item>
<item name="android:windowSplashScreenAnimatedIcon">@drawable/splash_icon</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
<style name="SplashTheme.Oled" parent="@android:style/Theme.Light.NoTitleBar">
<item name="android:windowBackground">@color/splash_oled</item>
<item name="android:windowSplashScreenAnimatedIcon">@drawable/splash_icon</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
<style name="SplashTheme.Light" parent="@android:style/Theme.Light.NoTitleBar">
<item name="android:windowBackground">@color/splash_light</item>
<item name="android:windowSplashScreenAnimatedIcon">@drawable/splash_icon</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
<style name="SplashTheme.System" parent="@android:style/Theme.Light.NoTitleBar">
<item name="android:windowBackground">@color/splash_background</item>
<item name="android:windowSplashScreenAnimatedIcon">@drawable/splash_icon</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
</resources>
@@ -1,4 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="ic_launcher_background">#ffffff</color>
<color name="splash_background">#F7F7F8</color>
<color name="splash_dark">#0E0F12</color>
<color name="splash_oled">#000000</color>
<color name="splash_light">#F7F7F8</color>
</resources>
+24 -1
View File
@@ -2,6 +2,7 @@
<resources>
<!-- Theme applied to the Android Window while the process is starting when the OS's Dark Mode setting is off -->
<style name="LaunchTheme" parent="@android:style/Theme.Light.NoTitleBar">
<item name="android:windowBackground">@color/splash_background</item>
<!-- Disable Android's default green focus highlight that appears during d-pad/keyboard navigation -->
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
@@ -13,9 +14,31 @@
This Theme is only used starting with V2 of Flutter's Android embedding. -->
<style name="NormalTheme" parent="@android:style/Theme.Light.NoTitleBar">
<item name="android:windowBackground">@android:color/black</item>
<item name="android:windowBackground">@color/splash_background</item>
<!-- Disable Android's default green focus highlight that appears during d-pad/keyboard navigation -->
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
<!-- Splash theme variants for setSplashScreenTheme -->
<style name="SplashTheme.Dark" parent="@android:style/Theme.Light.NoTitleBar">
<item name="android:windowBackground">@color/splash_dark</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
<style name="SplashTheme.Oled" parent="@android:style/Theme.Light.NoTitleBar">
<item name="android:windowBackground">@color/splash_oled</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
<style name="SplashTheme.Light" parent="@android:style/Theme.Light.NoTitleBar">
<item name="android:windowBackground">@color/splash_light</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
<style name="SplashTheme.System" parent="@android:style/Theme.Light.NoTitleBar">
<item name="android:windowBackground">@color/splash_background</item>
<item name="android:defaultFocusHighlightEnabled">false</item>
<item name="android:colorControlHighlight">@android:color/transparent</item>
</style>
</resources>
@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="utf-8"?>
<paths>
<!-- App-internal files directory (getApplicationDocumentsDirectory on Android) -->
<files-path name="app_files" path="." />
<!-- External files directory (fallback) -->
<external-files-path name="external_files" path="." />
<!-- External storage root (for custom download paths on shared storage) -->
<external-path name="external" path="." />
<!-- Cache directories -->
<cache-path name="cache" path="." />
<external-cache-path name="external_cache" path="." />
<!-- Filesystem root (ultimate fallback for any absolute path) -->
<root-path name="root" path="" />
</paths>
+25 -41
View File
@@ -4,60 +4,44 @@ Dotenv.load("../../.env")
default_platform(:android)
platform :android do
desc "Deploy a new version to the Google Play"
lane :deploy do
gradle(task: "clean bundleRelease")
# Get version code from pubspec.yaml
pubspec_path = "#{ENV['PWD']}/../pubspec.yaml"
pubspec_content = File.read(pubspec_path)
version_match = pubspec_content.match(/version:\s*(.+)\+(\d+)/)
if version_match
version_code = version_match[2].to_i
UI.message("Using version code: #{version_code}")
else
UI.user_error!("Could not extract version code from pubspec.yaml")
end
upload_to_play_store(
version_code: version_code,
skip_upload_changelogs: true,
skip_upload_metadata: true,
skip_upload_images: true,
skip_upload_screenshots: true
)
end
desc "Build release AAB"
lane :build do
# Navigate to Flutter project root and build
sh("cd #{ENV['PWD']}/.. && flutter build appbundle --dart-define=ENABLE_IN_APP_REVIEW=true")
end
desc "Build and deploy to Google Play Store"
lane :release do
# Build the Flutter app
sh("cd #{ENV['PWD']}/.. && flutter build appbundle --dart-define=ENABLE_IN_APP_REVIEW=true")
# Get version code from pubspec.yaml
# Get version from pubspec.yaml
pubspec_path = "#{ENV['PWD']}/../pubspec.yaml"
pubspec_content = File.read(pubspec_path)
version_match = pubspec_content.match(/version:\s*(.+)\+(\d+)/)
if version_match
version_name = version_match[1].strip
version_code = version_match[2].to_i
UI.message("Using version code: #{version_code}")
UI.message("Using version: #{version_name}+#{version_code}")
else
UI.user_error!("Could not extract version code from pubspec.yaml")
UI.user_error!("Could not extract version from pubspec.yaml")
end
# Upload to Play Store
debug_info_dir = "./debug-info/#{version_name}+#{version_code}"
git_commit = `git rev-parse --short HEAD`.strip
# Build the Flutter app
sh("cd #{ENV['PWD']}/.. && flutter build appbundle --dart-define=ENABLE_IN_APP_REVIEW=true --dart-define=ENABLE_SENTRY=true --dart-define=GIT_COMMIT=#{git_commit} --obfuscate --split-debug-info=#{debug_info_dir}/aab")
upload_to_play_store(
track: "internal",
release_status: "draft",
track: "production",
release_status: "completed",
version_code: version_code,
aab: "../build/app/outputs/bundle/release/app-release.aab"
)
# Build universal APK for Amazon Appstore (doesn't accept AABs, excludes x86 via env var)
sh("cd #{ENV['PWD']}/.. && AMAZON=1 flutter build apk --release --dart-define=ENABLE_SENTRY=true --dart-define=GIT_COMMIT=#{git_commit} --obfuscate --split-debug-info=#{debug_info_dir}/apk")
upload_to_amazon_appstore(
apk_paths: [
"../build/app/outputs/flutter-apk/app-release.apk"
],
overwrite_upload: true,
overwrite_upload_mode: 'reuse',
changes_not_sent_for_review: true
)
end
end
end
+5
View File
@@ -0,0 +1,5 @@
# Autogenerated by fastlane
#
# Ensure this file is checked in to source control!
gem 'fastlane-plugin-amazon_appstore'
+1 -1
View File
@@ -18,7 +18,7 @@ pluginManagement {
plugins {
id("dev.flutter.flutter-plugin-loader") version "1.0.0"
id("com.android.application") version "8.7.3" apply false
id("com.android.application") version "8.9.1" apply false
id("org.jetbrains.kotlin.android") version "2.1.0" apply false
}
+82
View File
@@ -0,0 +1,82 @@
<svg xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:cc="http://creativecommons.org/ns#" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:svg="http://www.w3.org/2000/svg" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" style="display:inline;enable-background:new" version="1.0" id="svg11300" viewBox="8 28 112 88">
<title id="title4162">Adwaita Icon Template</title>
<defs id="defs3">
<linearGradient id="linearGradient1965">
<stop style="stop-color:#62a0ea;stop-opacity:1" offset="0" id="stop1961"/>
<stop style="stop-color:#1a5fb4;stop-opacity:1" offset="1" id="stop1963"/>
</linearGradient>
<linearGradient id="linearGradient1959">
<stop style="stop-color:#ed333b;stop-opacity:1" offset="0" id="stop1955"/>
<stop style="stop-color:#1a5fb4;stop-opacity:0" offset="1" id="stop1957"/>
</linearGradient>
<radialGradient r="225" fy="-1136.1257" fx="58.953751" cy="-1136.1257" cx="58.953751" gradientTransform="matrix(0.27963724,0,0,0.19167088,14.08685,422.59065)" gradientUnits="userSpaceOnUse" id="radialGradient2319" xlink:href="#linearGradient1965"/>
<radialGradient r="225" fy="-173.6787" fx="312.7467" cy="-173.6787" cx="312.7467" gradientTransform="matrix(0.60444443,0,0,0.35619377,-109.038,345.86327)" gradientUnits="userSpaceOnUse" id="radialGradient2282" xlink:href="#linearGradient1959"/>
</defs>
<metadata id="metadata4">
<rdf:RDF>
<cc:Work rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage"/>
<dc:creator>
<cc:Agent>
<dc:title>GNOME Design Team</dc:title>
</cc:Agent>
</dc:creator>
<dc:source/>
<cc:license rdf:resource="http://creativecommons.org/licenses/by-sa/4.0/"/>
<dc:title>Adwaita Icon Template</dc:title>
<dc:subject>
<rdf:Bag/>
</dc:subject>
<dc:date/>
<dc:rights>
<cc:Agent>
<dc:title/>
</cc:Agent>
</dc:rights>
<dc:publisher>
<cc:Agent>
<dc:title/>
</cc:Agent>
</dc:publisher>
<dc:identifier/>
<dc:relation/>
<dc:language/>
<dc:coverage/>
<dc:description/>
<dc:contributor>
<cc:Agent>
<dc:title/>
</cc:Agent>
</dc:contributor>
</cc:Work>
<cc:License rdf:about="http://creativecommons.org/licenses/by-sa/4.0/">
<cc:permits rdf:resource="http://creativecommons.org/ns#Reproduction"/>
<cc:permits rdf:resource="http://creativecommons.org/ns#Distribution"/>
<cc:requires rdf:resource="http://creativecommons.org/ns#Notice"/>
<cc:requires rdf:resource="http://creativecommons.org/ns#Attribution"/>
<cc:permits rdf:resource="http://creativecommons.org/ns#DerivativeWorks"/>
<cc:requires rdf:resource="http://creativecommons.org/ns#ShareAlike"/>
</cc:License>
</rdf:RDF>
</metadata>
<g transform="translate(0,-172)" style="display:inline" id="layer1">
<g style="display:inline" id="layer9">
<path id="rect1792-1-3" d="m 8,200 v 88 h 8 v -8 h 8 v 8 h 80 v -8 h 8 v 8 h 8 v -88 h -8 v 8 h -8 v -8 H 24 v 8 h -8 v -8 z m 8,16 h 8 v 8 h -8 z m 88,0 h 8 v 8 h -8 z m -88,16 h 8 v 8 h -8 z m 88,0 h 8 v 8 h -8 z m -88,16 h 8 v 8 h -8 z m 88,0 h 8 v 8 h -8 z m -88,16 h 8 v 8 h -8 z m 88,0 h 8 v 8 h -8 z" style="display:inline;opacity:1;vector-effect:none;fill:url(#radialGradient2319);fill-opacity:1;stroke:none;stroke-width:0.33206606;stroke-linecap:butt;stroke-linejoin:bevel;stroke-miterlimit:4;stroke-dasharray:0.33206605, 0.66413209;stroke-dashoffset:0;stroke-opacity:0.94881891;marker:none;marker-start:none;marker-mid:none;marker-end:none;paint-order:normal;enable-background:new"/>
<path id="rect1794-0-6" d="m 8,200 v 88 h 8 v -8 h 8 v 8 h 80 v -8 h 8 v 8 h 8 v -88 h -8 v 8 h -8 v -8 H 24 v 8 h -8 v -8 z m 8,16 h 8 v 8 h -8 z m 88,0 h 8 v 8 h -8 z m -88,16 h 8 v 8 h -8 z m 88,0 h 8 v 8 h -8 z m -88,16 h 8 v 8 h -8 z m 88,0 h 8 v 8 h -8 z m -88,16 h 8 v 8 h -8 z m 88,0 h 8 v 8 h -8 z" style="display:inline;opacity:1;vector-effect:none;fill:url(#radialGradient2282);fill-opacity:1;stroke:none;stroke-width:0.33206606;stroke-linecap:butt;stroke-linejoin:bevel;stroke-miterlimit:4;stroke-dasharray:0.33206605, 0.66413209;stroke-dashoffset:0;stroke-opacity:0.94881891;marker:none;marker-start:none;marker-mid:none;marker-end:none;paint-order:normal;enable-background:new"/>
<path id="path2574-9" d="m 63.999999,218 a 20,20 0 0 0 -20,20 20,20 0 0 0 20,20 20,20 0 0 0 20,-20 20,20 0 0 0 -20,-20 z m -7.90625,10 h 1.8125 0.1875 c 0.34982,-0.003 0.69558,0.0774 1,0.25 l 14,8 c 0.6214,0.34377 0.9375,1.0469 0.9375,1.75 0,0.7031 -0.3161,1.40622 -0.9375,1.75 l -14,8 c -0.30442,0.1724 -0.65018,0.252 -1,0.25 h -0.1875 -1.8125 z" style="display:inline;opacity:0.15;vector-effect:none;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.33206606;stroke-linecap:butt;stroke-linejoin:bevel;stroke-miterlimit:4;stroke-dasharray:0.33206605, 0.66413209;stroke-dashoffset:0;stroke-opacity:0.94881891;marker:none;marker-start:none;marker-mid:none;marker-end:none;paint-order:normal;enable-background:new"/>
<g transform="translate(-9e-7,8)" style="display:inline;fill:#ffffff;enable-background:new" id="g2594">
<path style="opacity:1;vector-effect:none;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:0.33206606;stroke-linecap:butt;stroke-linejoin:bevel;stroke-miterlimit:4;stroke-dasharray:0.33206605, 0.66413209;stroke-dashoffset:0;stroke-opacity:0.94881891;marker:none;marker-start:none;marker-mid:none;marker-end:none;paint-order:normal" d="m 64,208 a 20,20 0 0 0 -20,20 20,20 0 0 0 20,20 20,20 0 0 0 20,-20 20,20 0 0 0 -20,-20 z m -7.90625,10 h 1.8125 0.1875 c 0.34982,-0.003 0.69558,0.0774 1,0.25 l 14,8 c 0.6214,0.34377 0.9375,1.0469 0.9375,1.75 0,0.7031 -0.3161,1.40622 -0.9375,1.75 l -14,8 c -0.30442,0.1724 -0.65018,0.252 -1,0.25 h -0.1875 -1.8125 z" id="path2574"/>
</g>
<g transform="translate(-9e-7,10)" style="display:inline;opacity:0.15;fill:#000000;enable-background:new" id="g2572">
<rect style="display:inline;opacity:1;vector-effect:none;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.33206606;stroke-linecap:butt;stroke-linejoin:bevel;stroke-miterlimit:4;stroke-dasharray:0.33206605, 0.66413209;stroke-dashoffset:0;stroke-opacity:0.94881891;marker:none;marker-start:none;marker-mid:none;marker-end:none;paint-order:normal;enable-background:new" id="rect2327-2" width="64" height="4" x="32" y="260" rx="2" ry="2"/>
<rect style="display:inline;opacity:1;vector-effect:none;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.24904953;stroke-linecap:butt;stroke-linejoin:bevel;stroke-miterlimit:4;stroke-dasharray:0.24904954, 0.49809907;stroke-dashoffset:0;stroke-opacity:0.94881891;marker:none;marker-start:none;marker-mid:none;marker-end:none;paint-order:normal;enable-background:new" id="rect2327-4-6" width="12" height="12" x="40" y="256" rx="6" ry="6"/>
</g>
<g transform="translate(-9e-7,8)" id="g2719" style="display:inline;enable-background:new">
<rect style="opacity:1;vector-effect:none;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:0.33206606;stroke-linecap:butt;stroke-linejoin:bevel;stroke-miterlimit:4;stroke-dasharray:0.33206605, 0.66413209;stroke-dashoffset:0;stroke-opacity:0.94881891;marker:none;marker-start:none;marker-mid:none;marker-end:none;paint-order:normal" id="rect2327" width="64" height="4" x="32" y="260" rx="2" ry="2"/>
<rect style="display:inline;opacity:1;vector-effect:none;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:0.24904953;stroke-linecap:butt;stroke-linejoin:bevel;stroke-miterlimit:4;stroke-dasharray:0.24904954, 0.49809907;stroke-dashoffset:0;stroke-opacity:0.94881891;marker:none;marker-start:none;marker-mid:none;marker-end:none;paint-order:normal;enable-background:new" id="rect2327-4" width="12" height="12" x="40" y="256" rx="6" ry="6"/>
</g>
<path id="path1927" d="m 16,213 v 3 h 8 v -3 z m 88,0 v 3 h 8 v -3 z m -88,16 v 3 h 8 v -3 z m 88,0 v 3 h 8 v -3 z m -88,16 v 3 h 8 v -3 z m 88,0 v 3 h 8 v -3 z m -88,16 v 3 h 8 v -3 z m 88,0 v 3 h 8 v -3 z m -88,16 v 3 h 8 v -3 z m 88,0 v 3 h 8 v -3 z m -96,8 v 3 h 8 v -3 z m 16,0 v 3 h 80 v -3 z m 88,0 v 3 h 8 v -3 z" style="display:inline;opacity:0.25;vector-effect:none;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.33206606;stroke-linecap:butt;stroke-linejoin:bevel;stroke-miterlimit:4;stroke-dasharray:0.33206605, 0.66413209;stroke-dashoffset:0;stroke-opacity:0.94881891;marker:none;marker-start:none;marker-mid:none;marker-end:none;paint-order:normal;enable-background:new"/>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 8.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 43 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 44 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

+46
View File
@@ -0,0 +1,46 @@
<svg xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:cc="http://creativecommons.org/ns#" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:svg="http://www.w3.org/2000/svg" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" id="svg2" version="1.1" inkscape:version="0.91 r13725" sodipodi:docname="mpv-gradient.svg" viewBox="4.05 4.05 55.9 55.9">
<defs id="defs4">
<linearGradient inkscape:collect="always" id="linearGradient4430">
<stop style="stop-color:#65376e;stop-opacity:1" offset="0" id="stop4432"/>
<stop style="stop-color:#4c2354;stop-opacity:1" offset="1" id="stop4434"/>
</linearGradient>
<linearGradient id="linearGradient4418" inkscape:collect="always">
<stop id="stop4420" offset="0" style="stop-color:#e6e2e8;stop-opacity:1"/>
<stop id="stop4422" offset="1" style="stop-color:#aaa3ad;stop-opacity:1"/>
</linearGradient>
<linearGradient inkscape:collect="always" id="linearGradient4402">
<stop style="stop-color:#320f38;stop-opacity:1" offset="0" id="stop4404"/>
<stop style="stop-color:#5a2963;stop-opacity:1" offset="1" id="stop4406"/>
</linearGradient>
<linearGradient inkscape:collect="always" id="linearGradient4392">
<stop style="stop-color:#6b3c74;stop-opacity:1" offset="0" id="stop4394"/>
<stop style="stop-color:#461b4d;stop-opacity:1" offset="1" id="stop4396"/>
</linearGradient>
<linearGradient inkscape:collect="always" id="linearGradient4382">
<stop style="stop-color:#fafafa;stop-opacity:1" offset="0" id="stop4384"/>
<stop style="stop-color:#bababa;stop-opacity:1" offset="1" id="stop4386"/>
</linearGradient>
<linearGradient inkscape:collect="always" xlink:href="#linearGradient4382" id="linearGradient5278" gradientUnits="userSpaceOnUse" gradientTransform="translate(-86.873198,699.81912)" x1="97.187729" y1="305.67371" x2="140.38228" y2="335.64926"/>
<linearGradient inkscape:collect="always" xlink:href="#linearGradient4392" id="linearGradient5280" gradientUnits="userSpaceOnUse" gradientTransform="translate(-32.973108,701.2155)" x1="50.828064" y1="298.31949" x2="78.197021" y2="339.65219"/>
<linearGradient inkscape:collect="always" xlink:href="#linearGradient4402" id="linearGradient5282" gradientUnits="userSpaceOnUse" gradientTransform="translate(-31.48364,700.09839)" x1="53.620815" y1="305.76682" x2="77.824654" y2="331.73938"/>
<linearGradient inkscape:collect="always" xlink:href="#linearGradient4418" id="linearGradient5284" gradientUnits="userSpaceOnUse" gradientTransform="translate(-87.152474,700.0053)" x1="110.31366" y1="312.28323" x2="126.88398" y2="329.41211"/>
<linearGradient inkscape:collect="always" xlink:href="#linearGradient4430" id="linearGradient5286" gradientUnits="userSpaceOnUse" gradientTransform="translate(-87.152474,700.0053)" x1="115.97468" y1="317.41763" x2="119.37984" y2="322.43457"/>
</defs>
<sodipodi:namedview id="base" pagecolor="#ffffff" bordercolor="#666666" borderopacity="1.0" inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="5.3710484" inkscape:cx="-19.490294" inkscape:cy="18.643164" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="false" units="px" inkscape:window-width="1920" inkscape:window-height="1016" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1"/>
<metadata id="metadata7">
<rdf:RDF>
<cc:Work rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage"/>
<dc:title/>
</cc:Work>
</rdf:RDF>
</metadata>
<g inkscape:label="Layer 1" inkscape:groupmode="layer" id="layer1" transform="translate(0,-988.3622)">
<circle style="opacity:1;fill:url(#linearGradient5278);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:0.10161044;stroke-linecap:round;stroke-linejoin:bevel;stroke-miterlimit:1;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.99215686" id="path4380-0" cx="32" cy="1020.3622" r="27.949194"/>
<circle style="opacity:1;fill:url(#linearGradient5280);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:0.0988237;stroke-linecap:round;stroke-linejoin:bevel;stroke-miterlimit:1;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.99215686" id="path4390-3" cx="32.727058" cy="1019.5079" r="25.950588"/>
<circle style="opacity:1;fill:url(#linearGradient5282);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:0.1;stroke-linecap:round;stroke-linejoin:bevel;stroke-miterlimit:1;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.99215686" id="path4400-3" cx="34.224396" cy="1017.7957" r="20"/>
<path style="fill:url(#linearGradient5284);fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:0.1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" d="m 44.481446,1020.4807 a 12.848894,12.848894 0 0 1 -12.84889,12.8489 12.848894,12.848894 0 0 1 -12.8489,-12.8489 12.848894,12.848894 0 0 1 12.8489,-12.8489 12.848894,12.848894 0 0 1 12.84889,12.8489 z" id="path4412-5" inkscape:connector-curvature="0"/>
<path style="fill:url(#linearGradient5286);fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:0.1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" d="m 28.374316,1014.709 0,11.4502 9.21608,-5.8647 z" id="path4426-2" inkscape:connector-curvature="0"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 5.5 KiB

+21
View File
@@ -0,0 +1,21 @@
<svg xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" xmlns="http://www.w3.org/2000/svg" xmlns:svg="http://www.w3.org/2000/svg" version="1.0" id="Layer_1" x="0px" y="0px" style="enable-background:new 0 0 898 630.4;" xml:space="preserve" sodipodi:docname="mx_player.svg" inkscape:version="1.4 (e7c3feb1, 2024-10-09)" viewBox="74 224 182.4 182.4"><defs id="defs10"/><sodipodi:namedview id="namedview10" pagecolor="#ffffff" bordercolor="#000000" borderopacity="0.25" inkscape:showpageshadow="2" inkscape:pageopacity="0.0" inkscape:pagecheckerboard="0" inkscape:deskcolor="#d1d1d1" inkscape:zoom="0.41160677" inkscape:cx="170.06523" inkscape:cy="99.609634" inkscape:window-width="1472" inkscape:window-height="843" inkscape:window-x="0" inkscape:window-y="34" inkscape:window-maximized="1" inkscape:current-layer="Layer_1"/>
<style type="text/css" id="style1">
.st0{fill:#3B8BEF;}
.st1{fill:#010101;}
.st2{fill:#020202;}
.st3{fill:#040303;}
.st4{fill:#040404;}
.st5{fill:#060606;}
.st6{fill:#FFFFFF;}
</style>
<path class="st0" d="M256.4,315.3c0,50.3-40.8,91.1-91.1,91.1c-0.1,0-0.2,0-0.4,0c-51.2-0.2-91.2-42.1-90.9-91.8 c0.3-49.3,40.4-90.8,91.6-90.6C215.9,224.2,256.5,265.1,256.4,315.3z M137.2,317.5v37.8c0,0.5,0,1,0,1.5c0.1,0.9,0.8,1.5,1.7,1.5 c0,0,0.1,0,0.1,0c0.5-0.1,0.9-0.3,1.3-0.5l8.8-5l57.8-33.1c0.4-0.2,0.8-0.5,1.2-0.8c0.8-0.6,0.9-1.6,0.4-2.4 c-0.1-0.1-0.2-0.3-0.4-0.4c-0.3-0.2-0.6-0.4-0.9-0.5l-66.4-38c-0.5-0.3-0.9-0.5-1.4-0.8c-0.8-0.4-1.8-0.1-2.2,0.8 c-0.1,0.2-0.2,0.4-0.2,0.7c0,0.5,0,1,0,1.5L137.2,317.5z" id="path1"/>
<path class="st6" d="M137.2,317.5v-37.9c0-0.5,0-1,0-1.5c0.1-0.9,0.9-1.6,1.8-1.5c0.2,0,0.4,0.1,0.6,0.1c0.5,0.2,1,0.5,1.4,0.8 l66.4,38c0.3,0.2,0.6,0.3,0.9,0.5c0.8,0.6,0.9,1.6,0.4,2.4c-0.1,0.1-0.2,0.3-0.4,0.4c-0.4,0.3-0.8,0.6-1.2,0.8l-57.8,33.1l-8.8,5 c-0.4,0.3-0.9,0.5-1.4,0.6c-0.9,0.1-1.7-0.5-1.8-1.3c0,0,0-0.1,0-0.1c0-0.5,0-1,0-1.5L137.2,317.5z" id="path10"/>
</svg>

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.5 KiB

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 194 KiB

+1
View File
@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="-276.65 -223.88 911.63 911.63"><defs><linearGradient id="linear-gradient" x1="22.67" y1="425.72" x2="201.83" y2="115.4" gradientUnits="userSpaceOnUse"><stop offset="0" stop-color="#ab543a"/><stop offset="1" stop-color="#ff7e57"/></linearGradient></defs><path fill="url(#linear-gradient)" d="M335.65,192.66L68.01,38.14C37.78,20.69,0,42.5,0,77.41v309.04c0,34.91,37.78,56.72,68.01,39.27l267.64-154.52c30.23-17.45,30.23-61.08,0-78.54ZM255.53,276.8c-19.1,17.66-38.75,26.49-58.4,26.49s-39.29-8.83-58.39-26.49c-14.39-13.3-28.55-20.05-42.11-20.05s-27.72,6.75-42.1,20.05c-4.87,4.5-12.46,4.2-16.96-.67-4.5-4.86-4.2-12.45.67-16.95,38.2-35.33,78.59-35.33,116.79,0,14.38,13.3,28.55,20.04,42.1,20.04s27.72-6.74,42.11-20.04c4.86-4.5,12.46-4.21,16.95.66,4.5,4.87,4.21,12.46-.66,16.96ZM255.53,204.04c-19.1,17.67-38.75,26.5-58.4,26.5s-39.29-8.83-58.39-26.5c-14.39-13.3-28.55-20.04-42.11-20.04s-27.72,6.74-42.1,20.04c-4.87,4.5-12.46,4.21-16.96-.66s-4.2-12.46.67-16.96c38.2-35.32,78.59-35.32,116.79,0,14.38,13.3,28.55,20.05,42.1,20.05s27.72-6.75,42.11-20.05c4.86-4.5,12.46-4.2,16.95.67,4.5,4.86,4.21,12.45-.66,16.95Z"/></svg>

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 59 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 21 KiB

+3
View File
@@ -0,0 +1,3 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" preserveAspectRatio="xMidYMid meet" viewBox="0 0 575 289.83" width="575" height="289.83"><defs><path d="M575 24.91C573.44 12.15 563.97 1.98 551.91 0C499.05 0 76.18 0 23.32 0C10.11 2.17 0 14.16 0 28.61C0 51.84 0 237.64 0 260.86C0 276.86 12.37 289.83 27.64 289.83C79.63 289.83 495.6 289.83 547.59 289.83C561.65 289.83 573.26 278.82 575 264.57C575 216.64 575 48.87 575 24.91Z" id="d1pwhf9wy2"></path><path d="M69.35 58.24L114.98 58.24L114.98 233.89L69.35 233.89L69.35 58.24Z" id="g5jjnq26yS"></path><path d="M201.2 139.15C197.28 112.38 195.1 97.5 194.67 94.53C192.76 80.2 190.94 67.73 189.2 57.09C185.25 57.09 165.54 57.09 130.04 57.09L130.04 232.74L170.01 232.74L170.15 116.76L186.97 232.74L215.44 232.74L231.39 114.18L231.54 232.74L271.38 232.74L271.38 57.09L211.77 57.09L201.2 139.15Z" id="i3Prh1JpXt"></path><path d="M346.71 93.63C347.21 95.87 347.47 100.95 347.47 108.89C347.47 115.7 347.47 170.18 347.47 176.99C347.47 188.68 346.71 195.84 345.2 198.48C343.68 201.12 339.64 202.43 333.09 202.43C333.09 190.9 333.09 98.66 333.09 87.13C338.06 87.13 341.45 87.66 343.25 88.7C345.05 89.75 346.21 91.39 346.71 93.63ZM367.32 230.95C372.75 229.76 377.31 227.66 381.01 224.67C384.7 221.67 387.29 217.52 388.77 212.21C390.26 206.91 391.14 196.38 391.14 180.63C391.14 174.47 391.14 125.12 391.14 118.95C391.14 102.33 390.49 91.19 389.48 85.53C388.46 79.86 385.93 74.71 381.88 70.09C377.82 65.47 371.9 62.15 364.12 60.13C356.33 58.11 343.63 57.09 321.54 57.09C319.27 57.09 307.93 57.09 287.5 57.09L287.5 232.74L342.78 232.74C355.52 232.34 363.7 231.75 367.32 230.95Z" id="a4ov9rRGQm"></path><path d="M464.76 204.7C463.92 206.93 460.24 208.06 457.46 208.06C454.74 208.06 452.93 206.98 452.01 204.81C451.09 202.65 450.64 197.72 450.64 190C450.64 185.36 450.64 148.22 450.64 143.58C450.64 135.58 451.04 130.59 451.85 128.6C452.65 126.63 454.41 125.63 457.13 125.63C459.91 125.63 463.64 126.76 464.6 129.03C465.55 131.3 466.03 136.15 466.03 143.58C466.03 146.58 466.03 161.58 466.03 188.59C465.74 197.84 465.32 203.21 464.76 204.7ZM406.68 231.21L447.76 231.21C449.47 224.5 450.41 220.77 450.6 220.02C454.32 224.52 458.41 227.9 462.9 230.14C467.37 232.39 474.06 233.51 479.24 233.51C486.45 233.51 492.67 231.62 497.92 227.83C503.16 224.05 506.5 219.57 507.92 214.42C509.34 209.26 510.05 201.42 510.05 190.88C510.05 185.95 510.05 146.53 510.05 141.6C510.05 131 509.81 124.08 509.34 120.83C508.87 117.58 507.47 114.27 505.14 110.88C502.81 107.49 499.42 104.86 494.98 102.98C490.54 101.1 485.3 100.16 479.26 100.16C474.01 100.16 467.29 101.21 462.81 103.28C458.34 105.35 454.28 108.49 450.64 112.7C450.64 108.89 450.64 89.85 450.64 55.56L406.68 55.56L406.68 231.21Z" id="fk968BpsX"></path></defs><g><g><g><use xlink:href="#d1pwhf9wy2" opacity="1" fill="#f6c700" fill-opacity="1"></use><g><use xlink:href="#d1pwhf9wy2" opacity="1" fill-opacity="0" stroke="#000000" stroke-width="1" stroke-opacity="0"></use></g></g><g><use xlink:href="#g5jjnq26yS" opacity="1" fill="#000000" fill-opacity="1"></use><g><use xlink:href="#g5jjnq26yS" opacity="1" fill-opacity="0" stroke="#000000" stroke-width="1" stroke-opacity="0"></use></g></g><g><use xlink:href="#i3Prh1JpXt" opacity="1" fill="#000000" fill-opacity="1"></use><g><use xlink:href="#i3Prh1JpXt" opacity="1" fill-opacity="0" stroke="#000000" stroke-width="1" stroke-opacity="0"></use></g></g><g><use xlink:href="#a4ov9rRGQm" opacity="1" fill="#000000" fill-opacity="1"></use><g><use xlink:href="#a4ov9rRGQm" opacity="1" fill-opacity="0" stroke="#000000" stroke-width="1" stroke-opacity="0"></use></g></g><g><use xlink:href="#fk968BpsX" opacity="1" fill="#000000" fill-opacity="1"></use><g><use xlink:href="#fk968BpsX" opacity="1" fill-opacity="0" stroke="#000000" stroke-width="1" stroke-opacity="0"></use></g></g></g></g></svg>

After

Width:  |  Height:  |  Size: 3.9 KiB

+20
View File
@@ -0,0 +1,20 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg id="svg3390" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://www.w3.org/2000/svg" height="141.25" viewBox="0 0 138.75 141.25" width="138.75" version="1.1" xmlns:cc="http://creativecommons.org/ns#" xmlns:dc="http://purl.org/dc/elements/1.1/">
<metadata id="metadata3396">
<rdf:RDF>
<cc:Work rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage"/>
<dc:title/>
</cc:Work>
</rdf:RDF>
</metadata>
<g id="layer1" fill="#f93208">
<path id="path3412" d="m20.154 40.829c-28.149 27.622-13.657 61.011-5.734 71.931 35.254 41.954 92.792 25.339 111.89-5.9071 4.7608-8.2027 22.554-53.467-23.976-78.009z"/>
<path id="path3471" d="m39.613 39.265 4.7778-8.8607 28.406-5.0384 11.119 9.2082z"/>
</g>
<g id="layer2">
<path id="path3437" d="m39.436 8.5696 8.9682-5.2826 6.7569 15.479c3.7925-6.3226 13.79-16.316 24.939-4.6684-4.7281 1.2636-7.5161 3.8553-7.7397 8.4768 15.145-4.1697 31.343 3.2127 33.539 9.0911-10.951-4.314-27.695 10.377-41.771 2.334 0.009 15.045-12.617 16.636-19.902 17.076 2.077-4.996 5.591-9.994 1.474-14.987-7.618 8.171-13.874 10.668-33.17 4.668 4.876-1.679 14.843-11.39 24.448-11.425-6.775-2.467-12.29-2.087-17.814-1.475 2.917-3.961 12.149-15.197 28.625-8.476z" fill="#02902e"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 1.4 KiB

+1
View File
@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" width="145" height="140"><path fill="#0fc755" d="M47.4 35.342c-13.607-7.935-12.32-25.203 2.097-31.88 26.124-6.531 29.117 13.78 22.652 30.412-6.542 24.11 18.095 23.662 19.925 10.067 3.605-18.412 19.394-26.695 31.67-16.359 12.598 12.135 7.074 36.581-17.827 34.187-16.03-1.545-19.552 19.585.839 21.183 32.228 1.915 42.49 22.167 31.04 35.865-15.993 15.15-37.691-4.439-45.512-19.505-6.8-9.307-17.321.11-13.423 6.502 12.983 19.465 2.923 31.229-10.906 30.62-13.37-.85-20.96-9.06-13.214-29.15 3.897-12.481-8.595-15.386-16.57-5.45-11.707 19.61-28.865 13.68-33.976 4.19-3.243-7.621-2.921-25.846 24.119-23.696 16.688 4.137 11.776-12.561-.63-13.633-9.245-.443-30.501-7.304-22.86-24.54 7.34-11.056 24.958-11.768 33.348 6.293 3.037 4.232 8.361 11.042 18.037 5.033 3.51-5.197 1.21-13.9-8.809-20.135z"/></svg>

After

Width:  |  Height:  |  Size: 833 B

+46
View File
@@ -0,0 +1,46 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg id="svg3880" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://www.w3.org/2000/svg" height="108.75" viewBox="0 0 143.75 108.75" width="143.75" version="1.1" xmlns:cc="http://creativecommons.org/ns#" xmlns:dc="http://purl.org/dc/elements/1.1/">
<metadata id="metadata3886">
<rdf:RDF>
<cc:Work rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage"/>
<dc:title/>
</cc:Work>
</rdf:RDF>
</metadata>
<g id="g3998" transform="matrix(.0042962 .96345 -.96345 .0042962 135.21 .16894)"></g>
<g id="layer4">
<path id="path3462" d="m96.641 2.9657c28.149 1.101 27.459 97.814 0.825 97.194l-74.45-9.973c-25.51-7.211-25.922-69.313-0.534-76.178z" fill="#07a23b"/>
<g fill="#fff">
<path id="path3505" d="m85.419 8.8789-63.171 8.9751c-4.2681 3.3648-6.9679 8.2192-7.5687 9.3296l65.017-6.963c1.3226-3.3762 4.3015-9.5395 5.7202-11.342z"/>
<path id="path3551" d="m78.042 28.008-65.329 5.5498c-2.494 4.757-3.169 10.65-3.3147 15.17l66.739-1.5147c0.0074-3.2891 0.55003-13.318 1.9052-19.206z"/>
<path id="path3553" d="m85.595 94.456-63.251-8.403c-4.2975-3.326-7.0398-8.1557-7.6503-9.2607l65.082 6.3737c1.3522 3.3644 4.3852 9.4999 5.8189 11.29z"/>
<path id="path3555" d="m78.051 75.394-65.375-4.957c-2.536-4.734-3.2627-10.621-3.4481-15.14l66.749 0.9101c0.03629 3.2889 0.66694 13.312 2.0737 19.188z"/>
</g>
</g>
<g id="layer5">
<path id="path4031" d="m100.36 10.836c-13.099 0.685-19.878 48.223-11.732 71.195l21.342-4.561c8.39-24.044 1.28-66.986-9.61-66.634z" fill="#03621e"/>
</g>
<g id="layer6" fill="#fdd600">
<path id="path4136" d="m99.087 78.942a6.1255 6.1255 0 0 1 -6.1238 6.1255 6.1255 6.1255 0 0 1 -6.1273 -6.122 6.1255 6.1255 0 0 1 6.1202 -6.1291 6.1255 6.1255 0 0 1 6.1309 6.1184"/>
<path id="path4174" d="m112.96 75.406a5.5952 5.5952 0 0 1 -5.5936 5.5952 5.5952 5.5952 0 0 1 -5.5968 -5.592 5.5952 5.5952 0 0 1 5.5903 -5.5985 5.5952 5.5952 0 0 1 5.6001 5.5887"/>
<path id="path4176" d="m120.39 74.743a4.9323 4.9323 0 0 1 -4.9309 4.9323 4.9323 4.9323 0 0 1 -4.9337 -4.9294 4.9323 4.9323 0 0 1 4.928 -4.9352 4.9323 4.9323 0 0 1 4.9366 4.9266"/>
<path id="path4178" d="m124.1 78.942a3.7391 3.7391 0 0 1 -3.738 3.7391 3.7391 3.7391 0 0 1 -3.7402 -3.7369 3.7391 3.7391 0 0 1 3.7358 -3.7412 3.7391 3.7391 0 0 1 3.7423 3.7347"/>
<path id="path4180" d="m131.08 83.14a5.0207 5.0207 0 0 1 -5.0192 5.0207 5.0207 5.0207 0 0 1 -5.0222 -5.0178 5.0207 5.0207 0 0 1 5.0163 -5.0236 5.0207 5.0207 0 0 1 5.0251 5.0148"/>
<path id="path4182" d="m135.86 91.67a5.5952 5.5952 0 0 1 -5.5936 5.5952 5.5952 5.5952 0 0 1 -5.5968 -5.592 5.5952 5.5952 0 0 1 5.5903 -5.5985 5.5952 5.5952 0 0 1 5.6001 5.5887"/>
<path id="path4184" d="m140.36 97.327a3.9158 3.9158 0 0 1 -3.9147 3.9158 3.9158 3.9158 0 0 1 -3.917 -3.9136 3.9158 3.9158 0 0 1 3.9124 -3.9181 3.9158 3.9158 0 0 1 3.9192 3.9113"/>
<path id="path4186" d="m140.45 99.625a4.181 4.181 0 0 1 -4.1798 4.181 4.181 4.181 0 0 1 -4.1822 -4.1786 4.181 4.181 0 0 1 4.1773 -4.1834 4.181 4.181 0 0 1 4.1846 4.1761"/>
<path id="path4188" d="m134.44 100.55a4.8439 4.8439 0 0 1 -4.8425 4.8439 4.8439 4.8439 0 0 1 -4.8453 -4.8411 4.8439 4.8439 0 0 1 4.8397 -4.8467 4.8439 4.8439 0 0 1 4.8481 4.8383"/>
<path id="path4190" d="m126.84 100.24a4.0042 4.0042 0 0 1 -4.0031 4.0042 4.0042 4.0042 0 0 1 -4.0054 -4.0019 4.0042 4.0042 0 0 1 4.0007 -4.0065 4.0042 4.0042 0 0 1 4.0077 3.9996"/>
<path id="path4192" d="m125.43 97.636a5.1091 5.1091 0 0 1 -5.1076 5.1091 5.1091 5.1091 0 0 1 -5.1106 -5.1061 5.1091 5.1091 0 0 1 5.1046 -5.112 5.1091 5.1091 0 0 1 5.1135 5.1031"/>
<path id="path4194" d="m117.12 98.078a5.1091 5.1091 0 0 1 -5.1076 5.1091 5.1091 5.1091 0 0 1 -5.1106 -5.1061 5.1091 5.1091 0 0 1 5.1046 -5.112 5.1091 5.1091 0 0 1 5.1135 5.1031"/>
<path id="path4196" d="m110.49 97.459a3.6065 3.6065 0 0 1 -3.6054 3.6065 3.6065 3.6065 0 0 1 -3.6075 -3.6044 3.6065 3.6065 0 0 1 3.6033 -3.6086 3.6065 3.6065 0 0 1 3.6096 3.6023"/>
<path id="path4198" d="m105.72 96.929a4.0484 4.0484 0 0 1 -4.0472 4.0484 4.0484 4.0484 0 0 1 -4.0496 -4.0461 4.0484 4.0484 0 0 1 4.0449 -4.0508 4.0484 4.0484 0 0 1 4.052 4.0437"/>
<path id="path4200" d="m94.71 80.271c2.1568-1.7217 5.4319-2.8842 9.5881-3.6062l11.579 0.61872 15.203 13.612-2.0329 9.6343-27.047-2.5633-4.7288 1.4584-11.183-17.899z"/>
</g>
<g id="layer7">
<path id="path4203" d="m85.913 71.627c3.2472 12.036 7.0507 22.57 12.64 28.284l-9.9879-1.591s-5.5685-25.456-4.8614-25.544c0.70711-0.08839 2.2097-1.149 2.2097-1.149z" fill="#09a339"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 4.6 KiB

+1
View File
@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" width="106.25" height="140"><path fill="#fa3106" d="M2.727 39.537c-.471-21.981 100.88-25.089 100.88-.42L92.91 117.56c-7.605 26.86-72.064 27.007-79.07.21z"/><g fill="#fff"><path d="M8.809 51.911l9.018 66.639c3.472 4.515 8.498 7.384 9.648 8.022l-6.921-68.576c-3.498-1.41-9.881-4.579-11.745-6.083zM28.629 59.776l5.453 68.898c4.926 2.652 11.04 3.391 15.73 3.566l-1.258-70.366c-3.414-.024-13.82-.642-19.925-2.098zM97.632 52.121l-9.019 66.643c-3.472 4.515-8.498 7.384-9.647 8.022l6.92-68.583c3.5-1.41 9.882-4.579 11.746-6.082zM77.812 59.986l-5.453 68.898c-4.926 2.652-11.04 3.391-15.73 3.566l1.258-70.366c3.414-.024 13.82-.642 19.925-2.098z"/></g><g fill="#ffd600"><circle cx="13.213" cy="31.252" r="6.816"/><circle cx="22.022" cy="27.687" r="6.607"/><circle cx="30.359" cy="19.769" r="5.925"/><circle cx="34.973" cy="15.155" r="6.03"/><circle cx="45.093" cy="17.095" r="4.929"/><circle cx="51.123" cy="9.597" r="6.24"/><circle cx="61.19" cy="9.387" r="6.554"/><circle cx="67.954" cy="13.635" r="4.929"/><circle cx="76.081" cy="17.672" r="5.925"/><circle cx="78.913" cy="22.706" r="4.352"/><circle cx="83.475" cy="26.324" r="5.243"/><circle cx="88.194" cy="34.398" r="5.768"/><path d="M87.355 35.447c5.79 2.799 1.352-2.213 10.696 2.097-9.574 15.338-74.774 16.892-90.291.525l-.21-3.985L38.59 16.99l22.863-6.606 15.52 9.962z"/></g></svg>

After

Width:  |  Height:  |  Size: 1.3 KiB

+1
View File
@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 185.04 133.4"><defs><linearGradient id="linear-gradient" y1="66.7" x2="185.04" y2="66.7" gradientUnits="userSpaceOnUse"><stop offset="0" stop-color="#90cea1"/><stop offset="0.56" stop-color="#3cbec9"/><stop offset="1" stop-color="#00b3e5"/></linearGradient></defs><title>Asset 4</title><g id="Layer_2" data-name="Layer 2"><g id="Layer_1-2" data-name="Layer 1"><path fill="url(#linear-gradient)" d="M51.06,66.7h0A17.67,17.67,0,0,1,68.73,49h-.1A17.67,17.67,0,0,1,86.3,66.7h0A17.67,17.67,0,0,1,68.63,84.37h.1A17.67,17.67,0,0,1,51.06,66.7Zm82.67-31.33h32.9A17.67,17.67,0,0,0,184.3,17.7h0A17.67,17.67,0,0,0,166.63,0h-32.9A17.67,17.67,0,0,0,116.06,17.7h0A17.67,17.67,0,0,0,133.73,35.37Zm-113,98h63.9A17.67,17.67,0,0,0,102.3,115.7h0A17.67,17.67,0,0,0,84.63,98H20.73A17.67,17.67,0,0,0,3.06,115.7h0A17.67,17.67,0,0,0,20.73,133.37Zm83.92-49h6.25L125.5,49h-8.35l-8.9,23.2h-.1L99.4,49H90.5Zm32.45,0h7.8V49h-7.8Zm22.2,0h24.95V77.2H167.1V70h15.35V62.8H167.1V56.2h16.25V49h-24ZM10.1,35.4h7.8V6.9H28V0H0V6.9H10.1ZM39,35.4h7.8V20.1H61.9V35.4h7.8V0H61.9V13.2H46.75V0H39Zm41.25,0h25V28.2H88V21h15.35V13.8H88V7.2h16.25V0h-24Zm-79,49H9V57.25h.1l9,27.15H24l9.3-27.15h.1V84.4h7.8V49H29.45l-8.2,23.1h-.1L13,49H1.2Zm112.09,49H126a24.59,24.59,0,0,0,7.56-1.15,19.52,19.52,0,0,0,6.35-3.37,16.37,16.37,0,0,0,4.37-5.5A16.91,16.91,0,0,0,146,115.8a18.5,18.5,0,0,0-1.68-8.25,15.1,15.1,0,0,0-4.52-5.53A18.55,18.55,0,0,0,133.07,99,33.54,33.54,0,0,0,125,98H113.29Zm7.81-28.2h4.6a17.43,17.43,0,0,1,4.67.62,11.68,11.68,0,0,1,3.88,1.88,9,9,0,0,1,2.62,3.18,9.87,9.87,0,0,1,1,4.52,11.92,11.92,0,0,1-1,5.08,8.69,8.69,0,0,1-2.67,3.34,10.87,10.87,0,0,1-4,1.83,21.57,21.57,0,0,1-5,.55H121.1Zm36.14,28.2h14.5a23.11,23.11,0,0,0,4.73-.5,13.38,13.38,0,0,0,4.27-1.65,9.42,9.42,0,0,0,3.1-3,8.52,8.52,0,0,0,1.2-4.68,9.16,9.16,0,0,0-.55-3.2,7.79,7.79,0,0,0-1.57-2.62,8.38,8.38,0,0,0-2.45-1.85,10,10,0,0,0-3.18-1v-.1a9.28,9.28,0,0,0,4.43-2.82,7.42,7.42,0,0,0,1.67-5,8.34,8.34,0,0,0-1.15-4.65,7.88,7.88,0,0,0-3-2.73,12.9,12.9,0,0,0-4.17-1.3,34.42,34.42,0,0,0-4.63-.32h-13.2Zm7.8-28.8h5.3a10.79,10.79,0,0,1,1.85.17,5.77,5.77,0,0,1,1.7.58,3.33,3.33,0,0,1,1.23,1.13,3.22,3.22,0,0,1,.47,1.82,3.63,3.63,0,0,1-.42,1.8,3.34,3.34,0,0,1-1.13,1.2,4.78,4.78,0,0,1-1.57.65,8.16,8.16,0,0,1-1.78.2H165Zm0,14.15h5.9a15.12,15.12,0,0,1,2.05.15,7.83,7.83,0,0,1,2,.55,4,4,0,0,1,1.58,1.17,3.13,3.13,0,0,1,.62,2,3.71,3.71,0,0,1-.47,1.95,4,4,0,0,1-1.23,1.3,4.78,4.78,0,0,1-1.67.7,8.91,8.91,0,0,1-1.83.2h-7Z"/></g></g></svg>

After

Width:  |  Height:  |  Size: 2.5 KiB

+1 -1
View File
@@ -21,6 +21,6 @@
<key>CFBundleVersion</key>
<string>1.0</string>
<key>MinimumOSVersion</key>
<string>13.0</string>
<string>15.5</string>
</dict>
</plist>
+1 -1
View File
@@ -1,5 +1,5 @@
# Uncomment this line to define a global platform for your project
platform :ios, '14.0'
platform :ios, '15.5'
# CocoaPods analytics sends network stats synchronously affecting flutter build latency.
ENV['COCOAPODS_DISABLE_STATS'] = 'true'
+93 -1
View File
@@ -1,4 +1,6 @@
PODS:
- background_downloader (0.0.1):
- Flutter
- connectivity_plus (0.0.1):
- Flutter
- device_info_plus (0.0.1):
@@ -6,8 +8,56 @@ PODS:
- file_picker (0.0.1):
- Flutter
- Flutter (1.0.0)
- GoogleDataTransport (10.1.0):
- nanopb (~> 3.30910.0)
- PromisesObjC (~> 2.4)
- GoogleMLKit/BarcodeScanning (7.0.0):
- GoogleMLKit/MLKitCore
- MLKitBarcodeScanning (~> 6.0.0)
- GoogleMLKit/MLKitCore (7.0.0):
- MLKitCommon (~> 12.0.0)
- GoogleToolboxForMac/Defines (4.2.1)
- GoogleToolboxForMac/Logger (4.2.1):
- GoogleToolboxForMac/Defines (= 4.2.1)
- "GoogleToolboxForMac/NSData+zlib (4.2.1)":
- GoogleToolboxForMac/Defines (= 4.2.1)
- GoogleUtilities/Environment (8.1.0):
- GoogleUtilities/Privacy
- GoogleUtilities/Logger (8.1.0):
- GoogleUtilities/Environment
- GoogleUtilities/Privacy
- GoogleUtilities/Privacy (8.1.0)
- GoogleUtilities/UserDefaults (8.1.0):
- GoogleUtilities/Logger
- GoogleUtilities/Privacy
- GTMSessionFetcher/Core (3.5.0)
- in_app_review (2.0.0):
- Flutter
- MLImage (1.0.0-beta6)
- MLKitBarcodeScanning (6.0.0):
- MLKitCommon (~> 12.0)
- MLKitVision (~> 8.0)
- MLKitCommon (12.0.0):
- GoogleDataTransport (~> 10.0)
- GoogleToolboxForMac/Logger (< 5.0, >= 4.2.1)
- "GoogleToolboxForMac/NSData+zlib (< 5.0, >= 4.2.1)"
- GoogleUtilities/Logger (~> 8.0)
- GoogleUtilities/UserDefaults (~> 8.0)
- GTMSessionFetcher/Core (< 4.0, >= 3.3.2)
- MLKitVision (8.0.0):
- GoogleToolboxForMac/Logger (< 5.0, >= 4.2.1)
- "GoogleToolboxForMac/NSData+zlib (< 5.0, >= 4.2.1)"
- GTMSessionFetcher/Core (< 4.0, >= 3.3.2)
- MLImage (= 1.0.0-beta6)
- MLKitCommon (~> 12.0)
- mobile_scanner (6.0.2):
- Flutter
- GoogleMLKit/BarcodeScanning (~> 7.0.0)
- nanopb (3.30910.0):
- nanopb/decode (= 3.30910.0)
- nanopb/encode (= 3.30910.0)
- nanopb/decode (3.30910.0)
- nanopb/encode (3.30910.0)
- os_media_controls (0.0.1):
- Flutter
- package_info_plus (0.4.5):
@@ -15,6 +65,12 @@ PODS:
- path_provider_foundation (0.0.1):
- Flutter
- FlutterMacOS
- PromisesObjC (2.4.0)
- Sentry/HybridSDK (8.46.0)
- sentry_flutter (8.14.2):
- Flutter
- FlutterMacOS
- Sentry/HybridSDK (= 8.46.0)
- shared_preferences_foundation (0.0.1):
- Flutter
- FlutterMacOS
@@ -56,14 +112,17 @@ PODS:
- Flutter
DEPENDENCIES:
- background_downloader (from `.symlinks/plugins/background_downloader/ios`)
- connectivity_plus (from `.symlinks/plugins/connectivity_plus/ios`)
- device_info_plus (from `.symlinks/plugins/device_info_plus/ios`)
- file_picker (from `.symlinks/plugins/file_picker/ios`)
- Flutter (from `Flutter`)
- in_app_review (from `.symlinks/plugins/in_app_review/ios`)
- mobile_scanner (from `.symlinks/plugins/mobile_scanner/ios`)
- os_media_controls (from `.symlinks/plugins/os_media_controls/ios`)
- package_info_plus (from `.symlinks/plugins/package_info_plus/ios`)
- path_provider_foundation (from `.symlinks/plugins/path_provider_foundation/darwin`)
- sentry_flutter (from `.symlinks/plugins/sentry_flutter/ios`)
- shared_preferences_foundation (from `.symlinks/plugins/shared_preferences_foundation/darwin`)
- sqflite_darwin (from `.symlinks/plugins/sqflite_darwin/darwin`)
- sqlite3_flutter_libs (from `.symlinks/plugins/sqlite3_flutter_libs/darwin`)
@@ -74,9 +133,23 @@ DEPENDENCIES:
SPEC REPOS:
trunk:
- GoogleDataTransport
- GoogleMLKit
- GoogleToolboxForMac
- GoogleUtilities
- GTMSessionFetcher
- MLImage
- MLKitBarcodeScanning
- MLKitCommon
- MLKitVision
- nanopb
- PromisesObjC
- Sentry
- sqlite3
EXTERNAL SOURCES:
background_downloader:
:path: ".symlinks/plugins/background_downloader/ios"
connectivity_plus:
:path: ".symlinks/plugins/connectivity_plus/ios"
device_info_plus:
@@ -87,12 +160,16 @@ EXTERNAL SOURCES:
:path: Flutter
in_app_review:
:path: ".symlinks/plugins/in_app_review/ios"
mobile_scanner:
:path: ".symlinks/plugins/mobile_scanner/ios"
os_media_controls:
:path: ".symlinks/plugins/os_media_controls/ios"
package_info_plus:
:path: ".symlinks/plugins/package_info_plus/ios"
path_provider_foundation:
:path: ".symlinks/plugins/path_provider_foundation/darwin"
sentry_flutter:
:path: ".symlinks/plugins/sentry_flutter/ios"
shared_preferences_foundation:
:path: ".symlinks/plugins/shared_preferences_foundation/darwin"
sqflite_darwin:
@@ -109,14 +186,29 @@ EXTERNAL SOURCES:
:path: ".symlinks/plugins/workmanager_apple/ios"
SPEC CHECKSUMS:
background_downloader: 50e91d979067b82081aba359d7d916b3ba5fadad
connectivity_plus: cb623214f4e1f6ef8fe7403d580fdad517d2f7dd
device_info_plus: 21fcca2080fbcd348be798aa36c3e5ed849eefbe
file_picker: 8fc6fe5e42585a217d44d22f79ec046cb8d81140
Flutter: cabc95a1d2626b1b06e7179b784ebcf0c0cde467
GoogleDataTransport: aae35b7ea0c09004c3797d53c8c41f66f219d6a7
GoogleMLKit: eff9e23ec1d90ea4157a1ee2e32a4f610c5b3318
GoogleToolboxForMac: d1a2cbf009c453f4d6ded37c105e2f67a32206d8
GoogleUtilities: 00c88b9a86066ef77f0da2fab05f65d7768ed8e1
GTMSessionFetcher: 5aea5ba6bd522a239e236100971f10cb71b96ab6
in_app_review: 7dd1ea365263f834b8464673f9df72c80c17c937
MLImage: 0ad1c5f50edd027672d8b26b0fee78a8b4a0fc56
MLKitBarcodeScanning: 0a3064da0a7f49ac24ceb3cb46a5bc67496facd2
MLKitCommon: 07c2c33ae5640e5380beaaa6e4b9c249a205542d
MLKitVision: 45e79d68845a2de77e2dd4d7f07947f0ed157b0e
mobile_scanner: af8f71879eaba2bbcb4d86c6a462c3c0e7f23036
nanopb: fad817b59e0457d11a5dfbde799381cd727c1275
os_media_controls: 86dceab6245a5325af90fc0fdebe243c42d789b4
package_info_plus: af8e2ca6888548050f16fa2f1938db7b5a5df499
path_provider_foundation: bb55f6dbba17d0dccd6737fe6f7f34fbd0376880
PromisesObjC: f5707f49cb48b9636751c5b2e7d227e43fba9f47
Sentry: da60d980b197a46db0b35ea12cb8f39af48d8854
sentry_flutter: 27892878729f42701297c628eb90e7c6529f3684
shared_preferences_foundation: 7036424c3d8ec98dfe75ff1667cb0cd531ec82bb
sqflite_darwin: 20b2a3a3b70e43edae938624ce550a3cbf66a3d0
sqlite3: 8d708bc63e9f4ce48f0ad9d6269e478c5ced1d9b
@@ -126,6 +218,6 @@ SPEC CHECKSUMS:
wakelock_plus: e29112ab3ef0b318e58cfa5c32326458be66b556
workmanager_apple: 904529ae31e97fc5be632cf628507652294a0778
PODFILE CHECKSUM: faeab82d8b6e3c9d039ddf62b7666988a3dea540
PODFILE CHECKSUM: 16bb7f67e16d8aaa2bfb97666803fbfb291b6559
COCOAPODS: 1.16.2
+41 -11
View File
@@ -12,9 +12,12 @@
3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; };
50DEEA8E23D1B433DE5341D6 /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2C12D873DE8572579684A82C /* Pods_Runner.framework */; };
6A48DFB02EA70C7100C1F7CD /* plezy.icon in Resources */ = {isa = PBXBuildFile; fileRef = 6A48DFAF2EA70C7100C1F7CD /* plezy.icon */; };
6A8A46212EDB320D0057B88C /* MPVKit-GPL in Frameworks */ = {isa = PBXBuildFile; productRef = 6A8A46202EDB320D0057B88C /* MPVKit-GPL */; };
6A8A46212EDB320D0057B88C /* MPVKit in Frameworks */ = {isa = PBXBuildFile; productRef = 6A8A46202EDB320D0057B88C /* MPVKit */; };
6A8A46252EDB370C0057B88C /* MpvPlayerPlugin.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6A8A46232EDB370C0057B88C /* MpvPlayerPlugin.swift */; };
6A8A46262EDB370C0057B88C /* MpvPlayerCore.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6A8A46222EDB370C0057B88C /* MpvPlayerCore.swift */; };
B1D51A6A2F00110000000001 /* MpvPlayerCoreBase.swift in Sources */ = {isa = PBXBuildFile; fileRef = B1D51A6A2F00110000000002 /* MpvPlayerCoreBase.swift */; };
B1D51A6A2F00110000000005 /* MpvPlayerPluginShared.swift in Sources */ = {isa = PBXBuildFile; fileRef = B1D51A6A2F00110000000006 /* MpvPlayerPluginShared.swift */; };
92F969587D0E464D999910F5 /* MpvPipController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 92F969587D0E464D999910F4 /* MpvPipController.swift */; };
74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; };
97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; };
97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; };
@@ -57,6 +60,9 @@
6A48DFAF2EA70C7100C1F7CD /* plezy.icon */ = {isa = PBXFileReference; lastKnownFileType = folder.iconcomposer.icon; path = plezy.icon; sourceTree = "<group>"; };
6A8A46222EDB370C0057B88C /* MpvPlayerCore.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MpvPlayerCore.swift; sourceTree = "<group>"; };
6A8A46232EDB370C0057B88C /* MpvPlayerPlugin.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MpvPlayerPlugin.swift; sourceTree = "<group>"; };
B1D51A6A2F00110000000002 /* MpvPlayerCoreBase.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = MpvPlayerCoreBase.swift; path = ../shared/apple/MpvPlayer/MpvPlayerCoreBase.swift; sourceTree = SOURCE_ROOT; };
B1D51A6A2F00110000000006 /* MpvPlayerPluginShared.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = MpvPlayerPluginShared.swift; path = ../shared/apple/MpvPlayer/MpvPlayerPluginShared.swift; sourceTree = SOURCE_ROOT; };
92F969587D0E464D999910F4 /* MpvPipController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MpvPipController.swift; sourceTree = "<group>"; };
74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = "<group>"; };
74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = "<group>"; };
@@ -86,7 +92,7 @@
buildActionMask = 2147483647;
files = (
50DEEA8E23D1B433DE5341D6 /* Pods_Runner.framework in Frameworks */,
6A8A46212EDB320D0057B88C /* MPVKit-GPL in Frameworks */,
6A8A46212EDB320D0057B88C /* MPVKit in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -113,8 +119,11 @@
6A8A46242EDB370C0057B88C /* MpvPlayer */ = {
isa = PBXGroup;
children = (
B1D51A6A2F00110000000002 /* MpvPlayerCoreBase.swift */,
B1D51A6A2F00110000000006 /* MpvPlayerPluginShared.swift */,
6A8A46222EDB370C0057B88C /* MpvPlayerCore.swift */,
6A8A46232EDB370C0057B88C /* MpvPlayerPlugin.swift */,
92F969587D0E464D999910F4 /* MpvPipController.swift */,
);
path = MpvPlayer;
sourceTree = "<group>";
@@ -214,6 +223,7 @@
9705A1C41CF9048500538489 /* Embed Frameworks */,
3B06AD1E1E4923F5004D2608 /* Thin Binary */,
2E10BAE564A4AFFCFF5B4EF0 /* [CP] Embed Pods Frameworks */,
BE3E47DA555D39F032C6A1DB /* [CP] Copy Pods Resources */,
);
buildRules = (
);
@@ -380,6 +390,23 @@
shellPath = /bin/sh;
shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build";
};
BE3E47DA555D39F032C6A1DB /* [CP] Copy Pods Resources */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputFileListPaths = (
"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-resources-${CONFIGURATION}-input-files.xcfilelist",
);
name = "[CP] Copy Pods Resources";
outputFileListPaths = (
"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-resources-${CONFIGURATION}-output-files.xcfilelist",
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-resources.sh\"\n";
showEnvVarsInLog = 0;
};
/* End PBXShellScriptBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
@@ -395,8 +422,11 @@
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
B1D51A6A2F00110000000001 /* MpvPlayerCoreBase.swift in Sources */,
B1D51A6A2F00110000000005 /* MpvPlayerPluginShared.swift in Sources */,
6A8A46252EDB370C0057B88C /* MpvPlayerPlugin.swift in Sources */,
6A8A46262EDB370C0057B88C /* MpvPlayerCore.swift in Sources */,
92F969587D0E464D999910F5 /* MpvPipController.swift in Sources */,
74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */,
1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */,
);
@@ -475,7 +505,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
IPHONEOS_DEPLOYMENT_TARGET = 15.5;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SUPPORTED_PLATFORMS = iphoneos;
@@ -496,7 +526,7 @@
INFOPLIST_FILE = Runner/Info.plist;
INFOPLIST_KEY_CFBundleDisplayName = Plezy;
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.entertainment";
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
IPHONEOS_DEPLOYMENT_TARGET = 15.5;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
@@ -609,7 +639,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
IPHONEOS_DEPLOYMENT_TARGET = 15.5;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
@@ -660,7 +690,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
IPHONEOS_DEPLOYMENT_TARGET = 15.5;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SUPPORTED_PLATFORMS = iphoneos;
@@ -683,7 +713,7 @@
INFOPLIST_FILE = Runner/Info.plist;
INFOPLIST_KEY_CFBundleDisplayName = Plezy;
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.entertainment";
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
IPHONEOS_DEPLOYMENT_TARGET = 15.5;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
@@ -710,7 +740,7 @@
INFOPLIST_FILE = Runner/Info.plist;
INFOPLIST_KEY_CFBundleDisplayName = Plezy;
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.entertainment";
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
IPHONEOS_DEPLOYMENT_TARGET = 15.5;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
@@ -765,16 +795,16 @@
repositoryURL = "https://github.com/edde746/MPVKit";
requirement = {
kind = revision;
revision = 0d0931fbbb25a3483a7edb46babd3f2f55abeefc;
revision = b2179eec26c6ceda339e6c6b512e457341768761;
};
};
/* End XCRemoteSwiftPackageReference section */
/* Begin XCSwiftPackageProductDependency section */
6A8A46202EDB320D0057B88C /* MPVKit-GPL */ = {
6A8A46202EDB320D0057B88C /* MPVKit */ = {
isa = XCSwiftPackageProductDependency;
package = 6A8A461F2EDB320D0057B88C /* XCRemoteSwiftPackageReference "MPVKit" */;
productName = "MPVKit-GPL";
productName = "MPVKit";
};
/* End XCSwiftPackageProductDependency section */
};
@@ -6,7 +6,7 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/edde746/MPVKit",
"state" : {
"revision" : "0d0931fbbb25a3483a7edb46babd3f2f55abeefc"
"revision" : "b2179eec26c6ceda339e6c6b512e457341768761"
}
}
],
@@ -6,7 +6,7 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/edde746/MPVKit",
"state" : {
"revision" : "0d0931fbbb25a3483a7edb46babd3f2f55abeefc"
"revision" : "b2179eec26c6ceda339e6c6b512e457341768761"
}
}
],
+10 -8
View File
@@ -3,18 +3,11 @@ import UIKit
import AVFoundation
@main
@objc class AppDelegate: FlutterAppDelegate {
@objc class AppDelegate: FlutterAppDelegate, FlutterImplicitEngineDelegate {
override func application(
_ application: UIApplication,
didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
) -> Bool {
GeneratedPluginRegistrant.register(with: self)
// Register MPV player plugin
if let registrar = self.registrar(forPlugin: "MpvPlayerPlugin") {
MpvPlayerPlugin.register(with: registrar)
}
// Configure audio session for media playback
do {
let session = AVAudioSession.sharedInstance()
@@ -28,4 +21,13 @@ import AVFoundation
return super.application(application, didFinishLaunchingWithOptions: launchOptions)
}
func didInitializeImplicitFlutterEngine(_ engineBridge: FlutterImplicitEngineBridge) {
GeneratedPluginRegistrant.register(with: engineBridge.pluginRegistry)
// Register MPV player plugin
if let registrar = engineBridge.pluginRegistry.registrar(forPlugin: "MpvPlayerPlugin") {
MpvPlayerPlugin.register(with: registrar)
}
}
}
+27 -1
View File
@@ -40,7 +40,7 @@
<key>NSLocalNetworkUsageDescription</key>
<string>This app needs to connect to your Plex Media Server on your local network.</string>
<key>NSCameraUsageDescription</key>
<string>Camera access is included by the WebRTC library used for Watch Together, but is not actively used by this app.</string>
<string>Camera is used to scan QR codes for Companion Remote pairing.</string>
<key>UIApplicationSupportsIndirectInputEvents</key>
<true/>
<key>UIFileSharingEnabled</key>
@@ -49,6 +49,11 @@
<string>LaunchScreen</string>
<key>UIMainStoryboardFile</key>
<string>Main</string>
<key>UIBackgroundModes</key>
<array>
<string>audio</string>
<string>fetch</string>
</array>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
@@ -62,5 +67,26 @@
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
<key>UIApplicationSceneManifest</key>
<dict>
<key>UIApplicationSupportsMultipleScenes</key>
<false/>
<key>UISceneConfigurations</key>
<dict>
<key>UIWindowSceneSessionRoleApplication</key>
<array>
<dict>
<key>UISceneClassName</key>
<string>UIWindowScene</string>
<key>UISceneDelegateClassName</key>
<string>FlutterSceneDelegate</string>
<key>UISceneConfigurationName</key>
<string>flutter</string>
<key>UISceneStoryboardFile</key>
<string>Main</string>
</dict>
</array>
</dict>
</dict>
</dict>
</plist>
+370
View File
@@ -0,0 +1,370 @@
import AVKit
import UIKit
/// Delegate to notify the plugin of PiP lifecycle events
protocol MpvPipDelegate: AnyObject {
/// Called when PiP is about to start (system or app-initiated)
func pipWillStart()
func pipDidStart()
/// Called when PiP stops. `restored` is true if the user pressed maximize (restore UI).
func pipDidStop(restored: Bool)
func pipDidFailToStart(error: Error?)
/// Forward play/pause commands from PiP overlay to mpv
func pipSetPlaying(_ playing: Bool)
/// Forward skip forward/backward commands from PiP overlay to mpv
func pipSkip(byInterval seconds: Double)
/// Query whether mpv is currently playing
var isPipPlaying: Bool { get }
/// Get total duration in seconds
var pipDuration: Double { get }
}
/// Encapsulates all iOS Picture-in-Picture logic using AVSampleBufferDisplayLayer.
/// Requires iOS 15+ for the ContentSource API; on older versions, `setup()` is a no-op.
class MpvPipController: NSObject {
// MARK: - Properties
private var pipController: AVPictureInPictureController?
private let sampleBufferLayer = AVSampleBufferDisplayLayer()
private var containerView: UIView?
weak var delegate: MpvPipDelegate?
/// Pointer to the sample buffer layer for passing to mpv as `wid`
var layerPointer: UnsafeMutableRawPointer {
Unmanaged.passUnretained(sampleBufferLayer).toOpaque()
}
// MARK: - Initialization
override init() {
super.init()
setup()
}
private func setup() {
guard #available(iOS 15.0, *) else { return }
do {
try AVAudioSession.sharedInstance().setCategory(.playback, mode: .moviePlayback)
try AVAudioSession.sharedInstance().setActive(true)
} catch {
print("[MpvPipController] Failed to configure audio session: \(error)")
}
// The sample buffer layer must be in a visible view hierarchy for
// isPictureInPicturePossible to become true.
if let windowScene = UIApplication.shared.connectedScenes.first as? UIWindowScene,
let window = windowScene.windows.first(where: { $0.isKeyWindow }) {
let view = UIView(frame: window.bounds)
view.autoresizingMask = [.flexibleWidth, .flexibleHeight]
view.clipsToBounds = true
view.isUserInteractionEnabled = false
sampleBufferLayer.frame = view.bounds
view.layer.addSublayer(sampleBufferLayer)
window.addSubview(view)
containerView = view
}
createPipController()
}
/// Helper that conforms to the iOS 15+ delegate protocols
private var delegateHelper: AnyObject?
private func createPipController() {
guard #available(iOS 15.0, *) else { return }
let helper = PipDelegateHelper(controller: self)
let contentSource = AVPictureInPictureController.ContentSource(
sampleBufferDisplayLayer: sampleBufferLayer,
playbackDelegate: helper
)
self.delegateHelper = helper
pipController = AVPictureInPictureController(contentSource: contentSource)
pipController?.delegate = helper
if #available(iOS 14.2, *) {
pipController?.canStartPictureInPictureAutomaticallyFromInline = false
}
}
/// Enable/disable system auto-PiP (starts PiP automatically on background transition)
func setAutoStart(_ enabled: Bool) {
guard #available(iOS 14.2, *) else { return }
pipController?.canStartPictureInPictureAutomaticallyFromInline = enabled
}
/// Push a black frame to the sample buffer layer so PiP has content
/// to display immediately (before vo_pip decodes the first real frame).
func pushBlankFrame(width: Int32 = 1920, height: Int32 = 1080) {
var pixelBuffer: CVPixelBuffer?
let attrs: [String: Any] = [
kCVPixelBufferIOSurfacePropertiesKey as String: [:],
]
let status = CVPixelBufferCreate(
kCFAllocatorDefault, Int(width), Int(height),
kCVPixelFormatType_32BGRA, attrs as CFDictionary, &pixelBuffer
)
guard status == kCVReturnSuccess, let pb = pixelBuffer else { return }
// Fill with black
CVPixelBufferLockBaseAddress(pb, [])
if let base = CVPixelBufferGetBaseAddress(pb) {
memset(base, 0, CVPixelBufferGetDataSize(pb))
}
CVPixelBufferUnlockBaseAddress(pb, [])
// Use current timebase time for PTS (if available) so the frame isn't stale
let pts: CMTime
if let tb = sampleBufferLayer.controlTimebase {
pts = CMTimebaseGetTime(tb)
} else {
pts = CMTime(value: 0, timescale: 30)
}
var timing = CMSampleTimingInfo(
duration: CMTime(value: 1, timescale: 30),
presentationTimeStamp: pts,
decodeTimeStamp: .invalid
)
// Create format description and sample buffer
var formatDesc: CMVideoFormatDescription?
CMVideoFormatDescriptionCreateForImageBuffer(
allocator: kCFAllocatorDefault,
imageBuffer: pb,
formatDescriptionOut: &formatDesc
)
guard let fmt = formatDesc else { return }
var sampleBuffer: CMSampleBuffer?
CMSampleBufferCreateReadyWithImageBuffer(
allocator: kCFAllocatorDefault,
imageBuffer: pb,
formatDescription: fmt,
sampleTiming: &timing,
sampleBufferOut: &sampleBuffer
)
guard let sb = sampleBuffer else { return }
// Set DisplayImmediately so it shows regardless of timebase timing
if let attachments = CMSampleBufferGetSampleAttachmentsArray(sb, createIfNecessary: true) as? [NSMutableDictionary],
let dict = attachments.first {
dict[kCMSampleAttachmentKey_DisplayImmediately] = true
}
sampleBufferLayer.enqueue(sb)
}
/// Sync the layer's controlTimebase with the actual playback position.
/// This makes the PiP progress bar show the correct time.
func syncTimebase(currentTime: Double, isPlaying: Bool) {
guard let timebase = sampleBufferLayer.controlTimebase else { return }
let cmTime = CMTime(seconds: currentTime, preferredTimescale: 1000)
CMTimebaseSetTime(timebase, time: cmTime)
CMTimebaseSetRate(timebase, rate: isPlaying ? 1.0 : 0.0)
}
/// Ensure the layer has a timebase and blank frame so the system considers
/// PiP possible (required for canStartPictureInPictureAutomaticallyFromInline).
func warmLayer(currentTime: Double, isPlaying: Bool) {
if sampleBufferLayer.controlTimebase == nil {
var timebase: CMTimebase?
CMTimebaseCreateWithSourceClock(
allocator: kCFAllocatorDefault,
sourceClock: CMClockGetHostTimeClock(),
timebaseOut: &timebase
)
if let tb = timebase {
sampleBufferLayer.controlTimebase = tb
}
}
syncTimebase(currentTime: currentTime, isPlaying: isPlaying)
pushBlankFrame()
}
// MARK: - Public API
static var isSupported: Bool {
guard #available(iOS 15.0, *) else { return false }
return AVPictureInPictureController.isPictureInPictureSupported()
}
/// Start PiP. When `waitForFrame` is false (auto-PiP), skips the frame
/// readiness check since the scene is about to deactivate.
func startPip(waitForFrame: Bool = true, completion: @escaping (Bool) -> Void) {
guard let pipController = pipController else {
completion(false)
return
}
var attempts = 0
func tryStart() {
let possible = pipController.isPictureInPicturePossible
let hasTimebase = sampleBufferLayer.controlTimebase != nil
let hasFrame: Bool
if !waitForFrame {
hasFrame = true // Skip frame check for auto-PiP
} else if #available(iOS 17.4, *) {
hasFrame = sampleBufferLayer.isReadyForDisplay
} else {
hasFrame = true
}
if possible && hasTimebase && hasFrame {
print("[MpvPipController] vo_pip ready after \(attempts) retries, starting PiP")
pipController.startPictureInPicture()
completion(true)
} else if attempts < 40 {
attempts += 1
DispatchQueue.main.asyncAfter(deadline: .now() + 0.05) { tryStart() }
} else {
print("[MpvPipController] PiP not ready after \(attempts) retries (possible=\(possible), timebase=\(hasTimebase))")
completion(false)
}
}
tryStart()
}
func stopPip() {
pipController?.stopPictureInPicture()
}
/// Invalidate the playback state so PiP updates its UI (play/pause button)
func invalidatePlaybackState() {
pipController?.invalidatePlaybackState()
}
/// Fully tear down PiP — removes the container view from the window and
/// destroys the AVPictureInPictureController so the system can no longer
/// trigger auto-PiP after the player is disposed.
func teardown() {
pipController?.stopPictureInPicture()
if #available(iOS 14.2, *) {
pipController?.canStartPictureInPictureAutomaticallyFromInline = false
}
pipController = nil
delegateHelper = nil
sampleBufferLayer.flushAndRemoveImage()
sampleBufferLayer.controlTimebase = nil
sampleBufferLayer.removeFromSuperlayer()
containerView?.removeFromSuperview()
containerView = nil
}
/// Flush enqueued sample buffers from the layer to free video frame memory
func flushLayer() {
sampleBufferLayer.flushAndRemoveImage()
}
}
// MARK: - PiP Delegate Helper (iOS 15+)
/// Separate class conforming to AVPictureInPictureControllerDelegate and
/// AVPictureInPictureSampleBufferPlaybackDelegate since these require iOS 15+
/// availability for the ContentSource-based delegate methods.
@available(iOS 15.0, *)
private class PipDelegateHelper: NSObject, AVPictureInPictureControllerDelegate,
AVPictureInPictureSampleBufferPlaybackDelegate
{
weak var controller: MpvPipController?
private var isRestoring = false
init(controller: MpvPipController) {
self.controller = controller
super.init()
}
// MARK: - AVPictureInPictureControllerDelegate
func pictureInPictureControllerWillStartPictureInPicture(
_ pictureInPictureController: AVPictureInPictureController
) {
print("[MpvPipController] PiP will start")
controller?.delegate?.pipWillStart()
}
func pictureInPictureControllerDidStartPictureInPicture(
_ pictureInPictureController: AVPictureInPictureController
) {
print("[MpvPipController] PiP did start")
controller?.delegate?.pipDidStart()
}
func pictureInPictureControllerDidStopPictureInPicture(
_ pictureInPictureController: AVPictureInPictureController
) {
let restored = isRestoring
isRestoring = false
print("[MpvPipController] PiP did stop (restored: \(restored))")
controller?.delegate?.pipDidStop(restored: restored)
}
func pictureInPictureController(
_ pictureInPictureController: AVPictureInPictureController,
failedToStartPictureInPictureWithError error: Error
) {
print("[MpvPipController] PiP failed to start: \(error)")
controller?.delegate?.pipDidFailToStart(error: error)
}
func pictureInPictureController(
_ pictureInPictureController: AVPictureInPictureController,
restoreUserInterfaceForPictureInPictureStopWithCompletionHandler completionHandler: @escaping (Bool) -> Void
) {
print("[MpvPipController] PiP restore user interface")
isRestoring = true
completionHandler(true)
}
func pictureInPictureControllerWillStopPictureInPicture(
_ pictureInPictureController: AVPictureInPictureController
) {
print("[MpvPipController] PiP will stop")
}
// MARK: - AVPictureInPictureSampleBufferPlaybackDelegate
func pictureInPictureController(
_ pictureInPictureController: AVPictureInPictureController,
setPlaying playing: Bool
) {
print("[MpvPipController] PiP setPlaying: \(playing)")
controller?.delegate?.pipSetPlaying(playing)
}
func pictureInPictureControllerTimeRangeForPlayback(
_ pictureInPictureController: AVPictureInPictureController
) -> CMTimeRange {
let duration = controller?.delegate?.pipDuration ?? 0
if duration > 0 {
return CMTimeRange(
start: .zero,
duration: CMTime(seconds: duration, preferredTimescale: 1000)
)
}
return CMTimeRange(start: .zero, duration: CMTime(seconds: 1, preferredTimescale: 1))
}
func pictureInPictureControllerIsPlaybackPaused(
_ pictureInPictureController: AVPictureInPictureController
) -> Bool {
return !(controller?.delegate?.isPipPlaying ?? false)
}
func pictureInPictureController(
_ pictureInPictureController: AVPictureInPictureController,
didTransitionToRenderSize newRenderSize: CMVideoDimensions
) {}
func pictureInPictureController(
_ pictureInPictureController: AVPictureInPictureController,
skipByInterval skipInterval: CMTime,
completion completionHandler: @escaping () -> Void
) {
let seconds = CMTimeGetSeconds(skipInterval)
print("[MpvPipController] PiP skip by \(seconds)s")
controller?.delegate?.pipSkip(byInterval: seconds)
completionHandler()
}
}
+111 -512
View File
@@ -1,66 +1,13 @@
import Libmpv
import UIKit
/// Protocol for receiving player events
protocol MpvPlayerDelegate: AnyObject {
func onPropertyChange(name: String, value: Any?)
func onEvent(name: String, data: [String: Any]?)
}
/// Core MPV player using Metal rendering for iOS.
class MpvPlayerCore: MpvPlayerCoreBase {
// Workaround for MoltenVK problems that cause flicker
// https://github.com/mpv-player/mpv/pull/13651
private class MetalLayer: CAMetalLayer {
override var drawableSize: CGSize {
get { return super.drawableSize }
set {
if Int(newValue.width) > 1 && Int(newValue.height) > 1 {
super.drawableSize = newValue
}
}
}
// Fix for target-colorspace-hint - needs main thread for EDR
@available(iOS 16.0, *)
override var wantsExtendedDynamicRangeContent: Bool {
get { return super.wantsExtendedDynamicRangeContent }
set {
if Thread.isMainThread {
super.wantsExtendedDynamicRangeContent = newValue
} else {
DispatchQueue.main.sync {
super.wantsExtendedDynamicRangeContent = newValue
}
}
}
}
}
/// Core MPV player using Metal rendering for iOS
class MpvPlayerCore: NSObject {
// MARK: - Properties
private var metalLayer: MetalLayer?
private var containerView: UIView? // Container for proper EDR activation
private var mpv: OpaquePointer?
private var containerView: UIView?
private weak var window: UIWindow?
private lazy var queue = DispatchQueue(label: "mpv", qos: .userInitiated)
weak var delegate: MpvPlayerDelegate?
private(set) var isInitialized = false
private var isDisposing = false // Flag to prevent race conditions during disposal
// HDR settings
private var hdrEnabled = true // User preference for HDR
private var lastSigPeak: Double = 0.0 // Last known sig-peak for re-evaluation
// Async command tracking to prevent UI blocking
private var pendingCommands: [UInt64: (Result<Void, Error>) -> Void] = [:]
private var pendingCommandsLock = NSLock()
private var nextRequestId: UInt64 = 1
// MARK: - Initialization
var isPipStarting = false
func initialize(in window: UIWindow) -> Bool {
guard !isInitialized else {
@@ -70,14 +17,11 @@ class MpvPlayerCore: NSObject {
self.window = window
// Create container view for proper EDR activation
// EDR requires the CAMetalLayer to be in a UIView hierarchy, not just window.layer
let container = UIView(frame: window.bounds)
container.backgroundColor = .clear
container.isUserInteractionEnabled = false
// Create Metal layer for video rendering
let layer = MetalLayer()
let layer = MpvMetalLayer()
layer.frame = container.bounds
layer.contentsScale = UIScreen.main.nativeScale
layer.framebufferOnly = true
@@ -87,13 +31,8 @@ class MpvPlayerCore: NSObject {
containerView = container
metalLayer = layer
// Add container view to window (behind Flutter's root view controller)
window.insertSubview(container, at: 0)
print(
"[MpvPlayerCore] Metal layer added to window via container view, frame: \(layer.frame)")
// Initialize MPV with this Metal layer
guard setupMpv() else {
print("[MpvPlayerCore] Failed to setup MPV")
layer.removeFromSuperlayer()
@@ -103,7 +42,6 @@ class MpvPlayerCore: NSObject {
return false
}
// Setup background/foreground notifications
setupNotifications()
isInitialized = true
@@ -111,61 +49,111 @@ class MpvPlayerCore: NSObject {
return true
}
private func setupMpv() -> Bool {
guard let metalLayer = metalLayer else { return false }
func switchToPipVO(layerPtr: UnsafeMutableRawPointer) -> Bool {
guard let mpv else { return false }
mpv = mpv_create()
guard mpv != nil else {
print("[MpvPlayerCore] Failed to create MPV context")
return false
}
print("[MpvPlayerCore] Switching to pip VO for PiP")
// Logging
#if DEBUG
checkError(mpv_request_log_messages(mpv, "info"))
#else
checkError(mpv_request_log_messages(mpv, "warn"))
#endif
metalLayer?.removeFromSuperlayer()
// Set the Metal layer as the render target (must use local var for &)
var layer = metalLayer
checkError(mpv_set_option(mpv, "wid", MPV_FORMAT_INT64, &layer))
mpv_set_property_string(mpv, "vid", "no")
// Video output settings for Metal/Vulkan
checkError(mpv_set_option_string(mpv, "vo", "gpu-next"))
checkError(mpv_set_option_string(mpv, "gpu-api", "vulkan"))
checkError(mpv_set_option_string(mpv, "gpu-context", "moltenvk"))
checkError(mpv_set_option_string(mpv, "hwdec", "videotoolbox"))
checkError(mpv_set_option_string(mpv, "target-colorspace-hint", "yes"))
var pointer = Int64(Int(bitPattern: layerPtr))
mpv_set_property(mpv, "wid", MPV_FORMAT_INT64, &pointer)
// Initialize MPV
let initResult = mpv_initialize(mpv)
if initResult < 0 {
print(
"[MpvPlayerCore] mpv_initialize failed: \(String(cString: mpv_error_string(initResult)))"
)
mpv_terminate_destroy(mpv)
mpv = nil
return false
}
mpv_set_property_string(mpv, "vo", "pip")
mpv_set_property_string(mpv, "vid", "auto")
// Set up wakeup callback for event handling
mpv_set_wakeup_callback(
mpv,
{ ctx in
guard let ctx = ctx else { return } // Safe guard instead of force unwrap
let core = Unmanaged<MpvPlayerCore>.fromOpaque(ctx).takeUnretainedValue()
core.readEvents()
}, UnsafeMutableRawPointer(Unmanaged.passUnretained(self).toOpaque()))
// Observe video-params/sig-peak for HDR detection
mpv_observe_property(mpv, 0, "video-params/sig-peak", MPV_FORMAT_DOUBLE)
print("[MpvPlayerCore] MPV initialized successfully")
print("[MpvPlayerCore] Switched to pip VO successfully")
return true
}
// MARK: - Background/Foreground Handling
func switchToGpuNextVO() -> Bool {
guard let mpv, let metalLayer else { return false }
print("[MpvPlayerCore] Switching back to gpu-next VO")
mpv_set_property_string(mpv, "vid", "no")
var layer = metalLayer
mpv_set_property(mpv, "wid", MPV_FORMAT_INT64, &layer)
applyGpuNextOptions()
mpv_set_property_string(mpv, "vid", "auto")
if metalLayer.superlayer == nil, let containerView {
containerView.layer.addSublayer(metalLayer)
}
print("[MpvPlayerCore] Switched back to gpu-next VO successfully")
return true
}
func setVisible(_ visible: Bool) {
guard let containerView else { return }
if visible {
containerView.removeFromSuperview()
window?.insertSubview(containerView, at: 0)
}
containerView.isHidden = !visible
}
func updateFrame(_ frame: CGRect? = nil) {
guard let metalLayer, let containerView else { return }
if let frame {
containerView.frame = frame
metalLayer.frame = containerView.bounds
} else if let window {
containerView.frame = window.bounds
metalLayer.frame = containerView.bounds
}
let scale = UIScreen.main.nativeScale
metalLayer.drawableSize = CGSize(
width: metalLayer.frame.width * scale,
height: metalLayer.frame.height * scale
)
}
/// Nudge mpv to present the current paused frame after switching back from PiP.
func forceDraw() {
command(["seek", "0", "relative+exact"])
}
override func updateEDRMode(sigPeak: Double) {
guard let metalLayer else { return }
var edrHeadroom: CGFloat = 1.0
if #available(iOS 16.0, *) {
edrHeadroom = containerView?.window?.screen.potentialEDRHeadroom ?? 1.0
metalLayer.wantsExtendedDynamicRangeContent =
hdrEnabled && sigPeak > 1.0 && edrHeadroom > 1.0
}
let shouldEnableEDR = hdrEnabled && sigPeak > 1.0 && edrHeadroom > 1.0
print(
"[MpvPlayerCore] EDR mode: \(shouldEnableEDR) (hdrEnabled: \(hdrEnabled), sigPeak: \(sigPeak), headroom: \(edrHeadroom))"
)
}
func dispose() {
NotificationCenter.default.removeObserver(self)
disposeSharedState(destroySynchronously: false)
metalLayer?.removeFromSuperlayer()
metalLayer = nil
containerView?.removeFromSuperview()
containerView = nil
isInitialized = false
print("[MpvPlayerCore] Disposed")
}
deinit {
dispose()
}
private func setupNotifications() {
NotificationCenter.default.addObserver(
@@ -183,7 +171,11 @@ class MpvPlayerCore: NSObject {
}
@objc private func enterBackground() {
// Disable video output to fix black screen when returning from background
if isPipActive || isPipStarting {
print("[MpvPlayerCore] Entering background - PiP active/starting, keeping video")
return
}
print("[MpvPlayerCore] Entering background - disabling video")
if mpv != nil {
mpv_set_option_string(mpv, "vid", "no")
@@ -191,407 +183,14 @@ class MpvPlayerCore: NSObject {
}
@objc private func enterForeground() {
// Re-enable video output
if isPipActive {
print("[MpvPlayerCore] Entering foreground - PiP active, skipping vid restore")
return
}
print("[MpvPlayerCore] Entering foreground - enabling video")
if mpv != nil {
mpv_set_option_string(mpv, "vid", "auto")
}
}
// MARK: - MPV Properties and Commands
func setProperty(_ name: String, value: String) {
guard mpv != nil else { return }
// Handle custom HDR toggle property
if name == "hdr-enabled" {
let enabled = value == "yes" || value == "true" || value == "1"
setHDREnabled(enabled)
return
}
mpv_set_property_string(mpv, name, value)
}
/// Enable or disable HDR mode
func setHDREnabled(_ enabled: Bool) {
hdrEnabled = enabled
print("[MpvPlayerCore] HDR enabled: \(enabled)")
// Update MPV's target-colorspace-hint
if mpv != nil {
mpv_set_property_string(mpv, "target-colorspace-hint", enabled ? "yes" : "no")
}
// Re-evaluate EDR mode with current sig-peak
DispatchQueue.main.async {
self.updateEDRMode(sigPeak: self.lastSigPeak)
}
}
func getProperty(_ name: String) -> String? {
guard mpv != nil else { return nil }
let cstr = mpv_get_property_string(mpv, name)
defer { mpv_free(cstr) }
return cstr.map { String(cString: $0) }
}
func observeProperty(_ name: String, format: String) {
guard mpv != nil else { return }
let mpvFormat: mpv_format
switch format {
case "double": mpvFormat = MPV_FORMAT_DOUBLE
case "flag": mpvFormat = MPV_FORMAT_FLAG
case "node": mpvFormat = MPV_FORMAT_NODE
case "string": mpvFormat = MPV_FORMAT_STRING
default: return
}
mpv_observe_property(mpv, 0, name, mpvFormat)
}
func command(_ args: [String]) {
guard mpv != nil, !args.isEmpty else { return }
command(args[0], args: Array(args.dropFirst()))
}
/// Execute an MPV command asynchronously to prevent UI blocking.
/// Uses mpv_command_async which returns immediately; the completion is called
/// when MPV_EVENT_COMMAND_REPLY is received.
func commandAsync(_ args: [String], completion: @escaping (Result<Void, Error>) -> Void) {
guard let mpv = mpv, !args.isEmpty else {
completion(.success(()))
return
}
// Generate unique request ID
pendingCommandsLock.lock()
let requestId = nextRequestId
nextRequestId += 1
pendingCommands[requestId] = completion
pendingCommandsLock.unlock()
// Build array of C strings for mpv_command_async
var cargs: [UnsafeMutablePointer<CChar>?] = args.map { strdup($0) }
cargs.append(nil) // null-terminate
// mpv_command_async returns immediately
cargs.withUnsafeBufferPointer { buffer in
var constPtrs = buffer.map { UnsafePointer($0) }
let result = mpv_command_async(mpv, requestId, &constPtrs)
if result < 0 {
// Command submission failed, complete immediately with error
pendingCommandsLock.lock()
if let pending = pendingCommands.removeValue(forKey: requestId) {
pendingCommandsLock.unlock()
let error = NSError(domain: "mpv", code: Int(result),
userInfo: [NSLocalizedDescriptionKey: String(cString: mpv_error_string(result))])
DispatchQueue.main.async { pending(.failure(error)) }
} else {
pendingCommandsLock.unlock()
}
}
}
// Free the C strings
for ptr in cargs {
free(ptr)
}
}
// MARK: - Visibility
func setVisible(_ visible: Bool) {
guard let container = containerView else { return }
if visible {
// Re-insert at the bottom of the window view stack
container.removeFromSuperview()
window?.insertSubview(container, at: 0)
}
container.isHidden = !visible
print("[MpvPlayerCore] setVisible(\(visible))")
}
func updateFrame(_ frame: CGRect? = nil) {
guard let metalLayer = metalLayer, let container = containerView else { return }
if let frame = frame {
container.frame = frame
metalLayer.frame = container.bounds
} else if let window = window {
container.frame = window.bounds
metalLayer.frame = container.bounds
}
// Update drawable size for proper scaling
let scale = UIScreen.main.nativeScale
metalLayer.drawableSize = CGSize(
width: metalLayer.frame.width * scale,
height: metalLayer.frame.height * scale
)
print("[MpvPlayerCore] updateFrame: \(container.frame)")
}
// MARK: - Private Helpers
private func command(_ cmd: String, args: [String] = []) {
guard mpv != nil else { return }
// Build array of C strings for mpv_command
var cargs: [UnsafeMutablePointer<CChar>?] = ([cmd] + args).map { strdup($0) }
cargs.append(nil) // null-terminate
defer {
for ptr in cargs {
free(ptr)
}
}
// mpv_command expects UnsafePointer, use withUnsafeBufferPointer for the conversion
cargs.withUnsafeBufferPointer { buffer in
var constPtrs = buffer.map { UnsafePointer($0) }
_ = mpv_command(mpv, &constPtrs)
}
}
private func readEvents() {
queue.async { [weak self] in
guard let self = self, !self.isDisposing, let mpv = self.mpv else { return }
while true {
let event = mpv_wait_event(mpv, 0)
guard let eventPtr = event else { break }
if eventPtr.pointee.event_id == MPV_EVENT_NONE {
break
}
self.handleEvent(eventPtr.pointee)
}
}
}
private func handleEvent(_ event: mpv_event) {
switch event.event_id {
case MPV_EVENT_PROPERTY_CHANGE:
guard let data = event.data else { break }
let property = data.assumingMemoryBound(to: mpv_event_property.self).pointee
let name = String(cString: property.name)
handlePropertyChange(name: name, property: property)
case MPV_EVENT_COMMAND_REPLY:
// Handle async command completion
let requestId = event.reply_userdata
pendingCommandsLock.lock()
let completion = pendingCommands.removeValue(forKey: requestId)
pendingCommandsLock.unlock()
if let completion = completion {
if event.error < 0 {
let error = NSError(domain: "mpv", code: Int(event.error),
userInfo: [NSLocalizedDescriptionKey: String(cString: mpv_error_string(event.error))])
DispatchQueue.main.async { completion(.failure(error)) }
} else {
DispatchQueue.main.async { completion(.success(())) }
}
}
case MPV_EVENT_FILE_LOADED:
DispatchQueue.main.async {
self.delegate?.onEvent(name: "file-loaded", data: nil)
}
case MPV_EVENT_END_FILE:
DispatchQueue.main.async {
self.delegate?.onEvent(name: "end-file", data: nil)
}
case MPV_EVENT_SHUTDOWN:
print("[MpvPlayerCore] MPV shutdown event")
case MPV_EVENT_PLAYBACK_RESTART:
DispatchQueue.main.async {
self.delegate?.onEvent(name: "playback-restart", data: nil)
}
case MPV_EVENT_LOG_MESSAGE:
if let msgPtr = event.data?.assumingMemoryBound(to: mpv_event_log_message.self) {
let msg = msgPtr.pointee
let prefix = msg.prefix.map { String(cString: $0) } ?? ""
let level = msg.level.map { String(cString: $0) } ?? ""
let text = msg.text.map { String(cString: $0) } ?? ""
DispatchQueue.main.async {
self.delegate?.onEvent(name: "log-message", data: [
"prefix": prefix,
"level": level,
"text": text
])
}
}
default:
break
}
}
private func handlePropertyChange(name: String, property: mpv_event_property) {
var value: Any?
switch property.format {
case MPV_FORMAT_DOUBLE:
if let ptr = property.data {
value = ptr.assumingMemoryBound(to: Double.self).pointee
}
case MPV_FORMAT_FLAG:
if let ptr = property.data {
value = ptr.assumingMemoryBound(to: Int32.self).pointee != 0
}
case MPV_FORMAT_NODE:
if let ptr = property.data {
let node = ptr.assumingMemoryBound(to: mpv_node.self).pointee
value = convertNode(node)
}
case MPV_FORMAT_STRING:
if let ptr = property.data {
let cstr = ptr.assumingMemoryBound(to: UnsafePointer<CChar>?.self).pointee
value = cstr.map { String(cString: $0) }
}
default:
break
}
// Handle sig-peak for HDR/EDR activation
if name == "video-params/sig-peak", let sigPeak = value as? Double {
lastSigPeak = sigPeak
DispatchQueue.main.async {
self.updateEDRMode(sigPeak: sigPeak)
}
}
DispatchQueue.main.async {
self.delegate?.onPropertyChange(name: name, value: value)
}
}
// MARK: - HDR/EDR Support
private func updateEDRMode(sigPeak: Double) {
guard let layer = metalLayer else { return }
// Check if screen supports EDR (iOS 16+)
var edrHeadroom: CGFloat = 1.0
if #available(iOS 16.0, *) {
edrHeadroom = containerView?.window?.screen.potentialEDRHeadroom ?? 1.0
}
let isHDRContent = sigPeak > 1.0
let screenSupportsEDR = edrHeadroom > 1.0
let shouldEnableEDR = hdrEnabled && isHDRContent && screenSupportsEDR
if #available(iOS 16.0, *) {
layer.wantsExtendedDynamicRangeContent = shouldEnableEDR
}
print(
"[MpvPlayerCore] EDR mode: \(shouldEnableEDR) (hdrEnabled: \(hdrEnabled), sigPeak: \(sigPeak), headroom: \(edrHeadroom))"
)
}
private func convertNode(_ node: mpv_node) -> Any? {
switch node.format {
case MPV_FORMAT_STRING:
return node.u.string.map { String(cString: $0) }
case MPV_FORMAT_FLAG:
return node.u.flag != 0
case MPV_FORMAT_INT64:
return node.u.int64
case MPV_FORMAT_DOUBLE:
return node.u.double_
case MPV_FORMAT_NODE_ARRAY:
guard let list = node.u.list?.pointee else { return nil }
var array = [Any]()
for i in 0..<Int(list.num) {
if let item = convertNode(list.values[i]) {
array.append(item)
}
}
return array
case MPV_FORMAT_NODE_MAP:
guard let list = node.u.list?.pointee else { return nil }
var dict = [String: Any]()
for i in 0..<Int(list.num) {
if let key = list.keys?[i].map({ String(cString: $0) }),
let val = convertNode(list.values[i])
{
dict[key] = val
}
}
return dict
default:
return nil
}
}
private func checkError(_ status: CInt) {
if status < 0 {
print("[MpvPlayerCore] MPV error: \(String(cString: mpv_error_string(status)))")
}
}
// MARK: - Cleanup
func dispose() {
// Set disposing flag first to prevent race conditions with event callbacks
isDisposing = true
NotificationCenter.default.removeObserver(self)
// Cancel any pending async commands
pendingCommandsLock.lock()
let pending = pendingCommands
pendingCommands.removeAll()
pendingCommandsLock.unlock()
// Complete pending commands with cancellation error
let cancelError = NSError(domain: "mpv", code: -1,
userInfo: [NSLocalizedDescriptionKey: "Player disposed"])
for (_, completion) in pending {
DispatchQueue.main.async { completion(.failure(cancelError)) }
}
let mpvHandle = mpv
mpv = nil
// Use async to avoid blocking the main thread (prevents deadlock)
queue.async {
if let handle = mpvHandle {
mpv_set_wakeup_callback(handle, nil, nil)
mpv_terminate_destroy(handle)
}
}
metalLayer?.removeFromSuperlayer()
metalLayer = nil
containerView?.removeFromSuperview()
containerView = nil
isInitialized = false
print("[MpvPlayerCore] Disposed")
}
deinit {
dispose()
}
}
+265 -124
View File
@@ -1,50 +1,65 @@
import UIKit
import Flutter
import AVKit
/// Flutter plugin that bridges MPV player to Dart via method and event channels
class MpvPlayerPlugin: NSObject, FlutterPlugin, FlutterStreamHandler, MpvPlayerDelegate {
class MpvPlayerPlugin: NSObject, FlutterPlugin, FlutterStreamHandler, MpvPluginShared {
// MARK: - Properties
private var playerCore: MpvPlayerCore?
private var eventSink: FlutterEventSink?
var eventSink: FlutterEventSink?
private weak var registrar: FlutterPluginRegistrar?
var nameToId: [String: Int] = [:]
// MpvPluginShared conformance
var coreBase: MpvPlayerCoreBase? { playerCore }
func setPlayerVisible(_ visible: Bool) { playerCore?.setVisible(visible) }
func updatePlayerFrame() { playerCore?.updateFrame() }
// PiP
private var pipController: MpvPipController?
private var pipChannel: FlutterMethodChannel?
private var autoPipEnabled = false
private var isManualPipRequest = false
private var pipTimebaseSyncTimer: Timer?
private var pendingInlineRestoreAfterPip = false
private var sceneActivationObserverRegistered = false
// MARK: - FlutterPlugin Registration
static func register(with registrar: FlutterPluginRegistrar) {
// Method channel for commands
let methodChannel = FlutterMethodChannel(
name: "com.plezy/mpv_player",
binaryMessenger: registrar.messenger()
)
// Event channel for state updates
let eventChannel = FlutterEventChannel(
name: "com.plezy/mpv_player/events",
binaryMessenger: registrar.messenger()
)
let pipChannel = FlutterMethodChannel(
name: "com.plezy/pip",
binaryMessenger: registrar.messenger()
)
let instance = MpvPlayerPlugin()
instance.registrar = registrar
instance.pipChannel = pipChannel
registrar.addMethodCallDelegate(instance, channel: methodChannel)
eventChannel.setStreamHandler(instance)
print("[MpvPlayerPlugin] Registered with Flutter")
pipChannel.setMethodCallHandler(instance.handlePipCall)
}
// MARK: - FlutterStreamHandler
func onListen(withArguments arguments: Any?, eventSink events: @escaping FlutterEventSink) -> FlutterError? {
self.eventSink = events
print("[MpvPlayerPlugin] Event stream connected")
return nil
}
func onCancel(withArguments arguments: Any?) -> FlutterError? {
self.eventSink = nil
print("[MpvPlayerPlugin] Event stream disconnected")
return nil
}
@@ -54,37 +69,195 @@ class MpvPlayerPlugin: NSObject, FlutterPlugin, FlutterStreamHandler, MpvPlayerD
switch call.method {
case "initialize":
handleInitialize(result: result)
case "dispose":
handleDispose(result: result)
case "setProperty":
handleSetProperty(call: call, result: result)
case "getProperty":
handleGetProperty(call: call, result: result)
case "observeProperty":
handleObserveProperty(call: call, result: result)
case "command":
handleCommand(call: call, result: result)
case "setVisible":
handleSetVisible(call: call, result: result)
case "isInitialized":
result(playerCore?.isInitialized ?? false)
case "updateFrame":
handleUpdateFrame(result: result)
case "setLogLevel":
handleSetLogLevel(call: call, result: result)
default:
result(FlutterMethodNotImplemented)
}
}
// MARK: - Method Handlers
// MARK: - PiP
private func ensurePipController() -> MpvPipController {
if let existing = pipController { return existing }
let controller = MpvPipController()
controller.delegate = self
pipController = controller
return controller
}
private func registerSceneActivationObserver() {
guard !sceneActivationObserverRegistered else { return }
NotificationCenter.default.addObserver(
self,
selector: #selector(sceneDidActivate),
name: UIScene.didActivateNotification,
object: nil
)
sceneActivationObserverRegistered = true
}
private func unregisterSceneActivationObserver() {
guard sceneActivationObserverRegistered else { return }
NotificationCenter.default.removeObserver(self, name: UIScene.didActivateNotification, object: nil)
sceneActivationObserverRegistered = false
}
private var isSceneActive: Bool {
UIApplication.shared.connectedScenes.contains { $0.activationState == .foregroundActive }
}
private func restoreInlinePlayerAfterPip() {
guard pendingInlineRestoreAfterPip,
let playerCore = playerCore,
!playerCore.isPipActive,
!playerCore.isPipStarting else { return }
print("[MpvPlayerPlugin] Restoring inline player after PiP")
playerCore.setVisible(true)
playerCore.updateFrame()
if playerCore.isPaused {
playerCore.forceDraw()
}
pendingInlineRestoreAfterPip = false
}
private func handlePipCall(_ call: FlutterMethodCall, result: @escaping FlutterResult) {
switch call.method {
case "isSupported":
result(MpvPipController.isSupported)
case "enter":
enterPip(manual: true, result: result)
case "setAutoPipReady":
if let args = call.arguments as? [String: Any], let ready = args["ready"] as? Bool {
autoPipEnabled = ready
if ready {
let pip = ensurePipController()
pip.setAutoStart(true)
// Warm the layer so the system considers PiP possible
if let pc = playerCore {
pip.warmLayer(currentTime: pc.timePos, isPlaying: !pc.isPaused)
}
} else {
pipController?.setAutoStart(false)
}
}
result(nil)
default:
result(FlutterMethodNotImplemented)
}
}
/// Switch to PiP VO and prepare the sample buffer layer for PiP display.
/// Returns the MpvPipController on success, nil on failure.
@discardableResult
private func switchToPipAndPrepare() -> MpvPipController? {
guard let playerCore = playerCore else { return nil }
let pip = ensurePipController()
guard playerCore.switchToPipVO(layerPtr: pip.layerPointer) else { return nil }
pendingInlineRestoreAfterPip = false
playerCore.isPipStarting = true
pip.pushBlankFrame()
pip.syncTimebase(currentTime: playerCore.timePos, isPlaying: !playerCore.isPaused)
pip.invalidatePlaybackState()
return pip
}
/// Manual PiP entry (button press). Auto-PiP is handled by the system via
/// canStartPictureInPictureAutomaticallyFromInline + pipWillStart delegate.
private func enterPip(manual: Bool, result: FlutterResult? = nil) {
guard MpvPipController.isSupported else {
result?(["success": false, "errorCode": "ios_version", "errorMessage": "Requires iOS 15.0+"])
return
}
guard playerCore != nil else {
result?(["success": false, "errorCode": "failed", "errorMessage": "Player not initialized"])
return
}
guard let pip = switchToPipAndPrepare() else {
result?(["success": false, "errorCode": "vo_switch_failed", "errorMessage": "Failed to switch VO"])
return
}
isManualPipRequest = manual
pip.startPip(waitForFrame: manual) { [weak self] started in
if started {
result?(["success": true])
} else {
self?.cleanupPip(notify: false)
result?(["success": false, "errorCode": "failed", "errorMessage": "PiP failed to start"])
}
}
}
/// Unified cleanup for all PiP exit paths
private func cleanupPip(notify: Bool, pause: Bool = false) {
playerCore?.isPipStarting = false
playerCore?.isPipActive = false
isManualPipRequest = false
stopPipTimebaseSync()
pipController?.flushLayer()
let restoredInlineVO = playerCore?.switchToGpuNextVO() ?? false
if pause { playerCore?.setProperty("pause", value: "yes") }
pendingInlineRestoreAfterPip = restoredInlineVO
if pendingInlineRestoreAfterPip {
if isSceneActive {
restoreInlinePlayerAfterPip()
} else {
print("[MpvPlayerPlugin] Deferring inline restore until scene activation")
}
}
if notify { pipChannel?.invokeMethod("onPipChanged", arguments: false) }
}
/// Scene became active — restore inline playback if needed and re-warm the
/// sample-buffer layer so future auto-PiP remains possible.
@objc private func sceneDidActivate() {
restoreInlinePlayerAfterPip()
if autoPipEnabled, let pip = pipController, let pc = playerCore, !pc.isPipActive {
pip.warmLayer(currentTime: pc.timePos, isPlaying: !pc.isPaused)
}
}
// MARK: - Timebase Sync
private func syncPipTimebase() {
guard let playerCore = playerCore, let pipController = pipController else { return }
pipController.syncTimebase(
currentTime: playerCore.timePos,
isPlaying: !playerCore.isPaused
)
}
private func startPipTimebaseSync() {
stopPipTimebaseSync()
pipTimebaseSyncTimer = Timer.scheduledTimer(withTimeInterval: 5.0, repeats: true) { [weak self] _ in
self?.syncPipTimebase()
}
}
private func stopPipTimebaseSync() {
pipTimebaseSyncTimer?.invalidate()
pipTimebaseSyncTimer = nil
}
// MARK: - Platform-Specific Method Handlers
private func handleInitialize(result: @escaping FlutterResult) {
DispatchQueue.main.async { [weak self] in
@@ -93,45 +266,43 @@ class MpvPlayerPlugin: NSObject, FlutterPlugin, FlutterStreamHandler, MpvPlayerD
return
}
// Check if already initialized
if self.playerCore?.isInitialized == true {
print("[MpvPlayerPlugin] Already initialized")
self.registerSceneActivationObserver()
result(true)
return
}
// Find the key window
guard let window = self.findKeyWindow() else {
print("[MpvPlayerPlugin] Failed to find key window")
result(FlutterError(code: "NO_WINDOW", message: "Could not find key window", details: nil))
return
}
// Create and initialize player core
let core = MpvPlayerCore()
core.delegate = self
guard core.initialize(in: window) else {
print("[MpvPlayerPlugin] Failed to initialize MPV")
result(FlutterError(code: "MPV_INIT_FAILED", message: "Failed to initialize MPV", details: nil))
return
}
self.playerCore = core
// Start hidden
self.registerSceneActivationObserver()
core.setVisible(false)
print("[MpvPlayerPlugin] Initialized successfully")
result(true)
}
}
private func handleDispose(result: @escaping FlutterResult) {
DispatchQueue.main.async { [weak self] in
self?.playerCore?.dispose()
self?.playerCore = nil
print("[MpvPlayerPlugin] Disposed")
guard let self = self else { result(nil); return }
self.pipController?.teardown()
self.pipController = nil
self.autoPipEnabled = false
self.pendingInlineRestoreAfterPip = false
self.unregisterSceneActivationObserver()
self.stopPipTimebaseSync()
self.playerCore?.dispose()
self.playerCore = nil
result(nil)
}
}
@@ -145,101 +316,15 @@ class MpvPlayerPlugin: NSObject, FlutterPlugin, FlutterStreamHandler, MpvPlayerD
}
playerCore?.setProperty(name, value: value)
if name == "pause" {
pipController?.invalidatePlaybackState()
if playerCore?.isPipActive == true { syncPipTimebase() }
}
result(nil)
}
private func handleGetProperty(call: FlutterMethodCall, result: @escaping FlutterResult) {
guard let args = call.arguments as? [String: Any],
let name = args["name"] as? String else {
result(FlutterError(code: "INVALID_ARGS", message: "Missing 'name' argument", details: nil))
return
}
let value = playerCore?.getProperty(name)
result(value)
}
private func handleObserveProperty(call: FlutterMethodCall, result: @escaping FlutterResult) {
guard let args = call.arguments as? [String: Any],
let name = args["name"] as? String,
let format = args["format"] as? String else {
result(FlutterError(code: "INVALID_ARGS", message: "Missing 'name' or 'format' argument", details: nil))
return
}
playerCore?.observeProperty(name, format: format)
result(nil)
}
private func handleCommand(call: FlutterMethodCall, result: @escaping FlutterResult) {
guard let args = call.arguments as? [String: Any],
let commandArgs = args["args"] as? [String] else {
result(FlutterError(code: "INVALID_ARGS", message: "Missing 'args' argument", details: nil))
return
}
// Use async command to prevent UI blocking during network operations
playerCore?.commandAsync(commandArgs) { commandResult in
switch commandResult {
case .success:
result(nil)
case .failure(let error):
result(FlutterError(code: "COMMAND_FAILED", message: error.localizedDescription, details: nil))
}
} ?? result(nil)
}
private func handleSetVisible(call: FlutterMethodCall, result: @escaping FlutterResult) {
guard let args = call.arguments as? [String: Any],
let visible = args["visible"] as? Bool else {
result(FlutterError(code: "INVALID_ARGS", message: "Missing 'visible' argument", details: nil))
return
}
DispatchQueue.main.async { [weak self] in
self?.playerCore?.setVisible(visible)
// Update frame when becoming visible
if visible {
self?.playerCore?.updateFrame()
}
result(nil)
}
}
private func handleUpdateFrame(result: @escaping FlutterResult) {
DispatchQueue.main.async { [weak self] in
self?.playerCore?.updateFrame()
result(nil)
}
}
// MARK: - MpvPlayerDelegate
func onPropertyChange(name: String, value: Any?) {
guard let eventSink = eventSink else { return }
var event: [String: Any] = ["type": "property", "name": name]
if let value = value {
event["value"] = value
}
eventSink(event)
}
func onEvent(name: String, data: [String: Any]?) {
guard let eventSink = eventSink else { return }
var event: [String: Any] = ["type": "event", "name": name]
if let data = data {
event["data"] = data
}
eventSink(event)
}
// MARK: - Helpers
private func findKeyWindow() -> UIWindow? {
@@ -250,3 +335,59 @@ class MpvPlayerPlugin: NSObject, FlutterPlugin, FlutterStreamHandler, MpvPlayerD
return window
}
}
// MARK: - MpvPipDelegate
extension MpvPlayerPlugin: MpvPipDelegate {
func pipWillStart() {
// If PiP was system-initiated (not via our enterPip), switch VO now
guard let playerCore = playerCore, !playerCore.isPipStarting else { return }
print("[MpvPlayerPlugin] System-initiated PiP detected, switching VO")
if switchToPipAndPrepare() == nil {
print("[MpvPlayerPlugin] VO switch failed for system-initiated PiP")
pipController?.stopPip()
}
}
func pipDidStart() {
playerCore?.isPipStarting = false
playerCore?.isPipActive = true
pendingInlineRestoreAfterPip = false
pipChannel?.invokeMethod("onPipChanged", arguments: true)
syncPipTimebase()
startPipTimebaseSync()
if isManualPipRequest {
isManualPipRequest = false
UIControl().sendAction(#selector(URLSessionTask.suspend), to: UIApplication.shared, for: nil)
}
}
func pipDidStop(restored: Bool) {
cleanupPip(notify: true, pause: !restored)
}
func pipDidFailToStart(error: Error?) {
cleanupPip(notify: true)
}
func pipSetPlaying(_ playing: Bool) {
playerCore?.setProperty("pause", value: playing ? "no" : "yes")
pipController?.invalidatePlaybackState()
syncPipTimebase()
}
func pipSkip(byInterval seconds: Double) {
guard let playerCore = playerCore else { return }
let newTime = max(0, playerCore.timePos + seconds)
playerCore.command(["seek", String(newTime), "absolute"])
DispatchQueue.main.asyncAfter(deadline: .now() + 0.1) { [weak self] in
self?.syncPipTimebase()
self?.pipController?.invalidatePlaybackState()
}
}
var isPipPlaying: Bool { !(playerCore?.isPaused ?? true) }
var pipDuration: Double { playerCore?.duration ?? 0 }
}
+4 -31
View File
@@ -4,39 +4,12 @@ Dotenv.load("../../.env")
default_platform(:ios)
platform :ios do
desc "Push a new beta build to TestFlight"
lane :beta do
build_app(workspace: "Runner.xcworkspace", scheme: "Runner")
upload_to_testflight
end
desc "Push a new release build to the App Store"
lane :release do
build_app(workspace: "Runner.xcworkspace", scheme: "Runner")
upload_to_app_store
end
desc "Build release IPA"
lane :build do
# Navigate to Flutter project root and build
sh("cd #{ENV['PWD']}/.. && flutter build ipa --dart-define=ENABLE_IN_APP_REVIEW=true")
end
desc "Build and deploy to TestFlight"
lane :deploy_testflight do
# Build the Flutter app
sh("cd #{ENV['PWD']}/.. && flutter build ipa --dart-define=ENABLE_IN_APP_REVIEW=true")
# Upload to TestFlight
upload_to_testflight(
skip_waiting_for_build_processing: true
)
end
desc "Build and deploy to App Store"
lane :deploy_appstore do
git_commit = `git rev-parse --short HEAD`.strip
# Build the Flutter app
sh("cd #{ENV['PWD']}/.. && flutter build ipa --dart-define=ENABLE_IN_APP_REVIEW=true")
sh("cd #{ENV['PWD']}/.. && flutter build ipa --dart-define=ENABLE_IN_APP_REVIEW=true --dart-define=ENABLE_SENTRY=true --dart-define=GIT_COMMIT=#{git_commit}")
# Upload to App Store
upload_to_app_store(
@@ -46,4 +19,4 @@ platform :ios do
skip_screenshots: true, # https://github.com/fastlane/fastlane/issues/29735
)
end
end
end
File diff suppressed because one or more lines are too long
+15 -10
View File
@@ -7,6 +7,7 @@ import 'package:path/path.dart' as p;
import 'tables.dart';
import '../models/download_models.dart';
import '../utils/app_logger.dart';
import '../utils/global_key_utils.dart';
part 'app_database.g.dart';
@@ -16,7 +17,7 @@ class AppDatabase extends _$AppDatabase {
AppDatabase() : super(_openConnection());
@override
int get schemaVersion => 7; // Added OfflineWatchProgress table
int get schemaVersion => 8; // Added bgTaskId column to DownloadedMedia
@override
MigrationStrategy get migration {
@@ -25,11 +26,18 @@ class AppDatabase extends _$AppDatabase {
await m.createAll();
},
onUpgrade: (Migrator m, int from, int to) async {
// Additive migration for schema version 7
if (from < 7) {
appLogger.i('Adding OfflineWatchProgress table (v7 migration)');
await m.createTable(offlineWatchProgress);
}
if (from < 8) {
appLogger.i('Adding bgTaskId column to DownloadedMedia (v8 migration)');
try {
await m.addColumn(downloadedMedia, downloadedMedia.bgTaskId);
} catch (e) {
appLogger.w('bgTaskId column may already exist: $e');
}
}
},
);
}
@@ -92,7 +100,7 @@ class AppDatabase extends _$AppDatabase {
required int duration,
required bool shouldMarkWatched,
}) async {
final globalKey = '$serverId:$ratingKey';
final globalKey = buildGlobalKey(serverId, ratingKey);
final now = DateTime.now().millisecondsSinceEpoch;
// Check for existing progress entry
@@ -137,7 +145,7 @@ class AppDatabase extends _$AppDatabase {
required String ratingKey,
required String actionType, // 'watched' or 'unwatched'
}) async {
final globalKey = '$serverId:$ratingKey';
final globalKey = buildGlobalKey(serverId, ratingKey);
final now = DateTime.now().millisecondsSinceEpoch;
// Remove conflicting actions (opposite action type and progress)
@@ -197,12 +205,9 @@ class AppDatabase extends _$AppDatabase {
LazyDatabase _openConnection() {
return LazyDatabase(() async {
final Directory dbFolder;
if (Platform.isAndroid || Platform.isIOS) {
dbFolder = await getApplicationDocumentsDirectory();
} else {
dbFolder = await getApplicationSupportDirectory();
}
final dbFolder = (Platform.isAndroid || Platform.isIOS)
? await getApplicationDocumentsDirectory()
: await getApplicationSupportDirectory();
final file = File(p.join(dbFolder.path, 'plezy_downloads.db'));
File diff suppressed because it is too large Load Diff
+167
View File
@@ -0,0 +1,167 @@
import 'package:drift/drift.dart';
import 'app_database.dart';
import '../models/download_models.dart';
/// Extension methods on AppDatabase for download operations
extension DownloadDatabaseOperations on AppDatabase {
/// Insert a new download into the database
Future<void> insertDownload({
required String serverId,
required String ratingKey,
required String globalKey,
required String type,
String? parentRatingKey,
String? grandparentRatingKey,
required int status,
}) async {
await into(downloadedMedia).insert(
DownloadedMediaCompanion.insert(
serverId: serverId,
ratingKey: ratingKey,
globalKey: globalKey,
type: type,
parentRatingKey: Value(parentRatingKey),
grandparentRatingKey: Value(grandparentRatingKey),
status: status,
),
mode: InsertMode.insertOrReplace,
);
}
/// Add item to download queue
Future<void> addToQueue({
required String mediaGlobalKey,
int priority = 0,
bool downloadSubtitles = true,
bool downloadArtwork = true,
}) async {
await into(downloadQueue).insert(
DownloadQueueCompanion.insert(
mediaGlobalKey: mediaGlobalKey,
priority: Value(priority),
addedAt: DateTime.now().millisecondsSinceEpoch,
downloadSubtitles: Value(downloadSubtitles),
downloadArtwork: Value(downloadArtwork),
),
mode: InsertMode.insertOrReplace,
);
}
/// Get next item from queue (highest priority, oldest first)
/// Only returns items that are not paused
Future<DownloadQueueItem?> getNextQueueItem() async {
// Join with downloadedMedia to check status and filter out paused items
final query = select(
downloadQueue,
).join([innerJoin(downloadedMedia, downloadedMedia.globalKey.equalsExp(downloadQueue.mediaGlobalKey))]);
query
..where(downloadedMedia.status.equals(DownloadStatus.queued.index))
..orderBy([
OrderingTerm(expression: downloadQueue.priority, mode: OrderingMode.desc),
OrderingTerm(expression: downloadQueue.addedAt),
])
..limit(1);
final result = await query.getSingleOrNull();
return result?.readTable(downloadQueue);
}
/// Update download status
Future<void> updateDownloadStatus(String globalKey, int status) async {
await (update(
downloadedMedia,
)..where((t) => t.globalKey.equals(globalKey))).write(DownloadedMediaCompanion(status: Value(status)));
}
/// Update download progress
Future<void> updateDownloadProgress(String globalKey, int progress, int downloadedBytes, int totalBytes) async {
await (update(downloadedMedia)..where((t) => t.globalKey.equals(globalKey))).write(
DownloadedMediaCompanion(
progress: Value(progress),
downloadedBytes: Value(downloadedBytes),
totalBytes: Value(totalBytes),
),
);
}
/// Update video file path
Future<void> updateVideoFilePath(String globalKey, String filePath) async {
await (update(downloadedMedia)..where((t) => t.globalKey.equals(globalKey))).write(
DownloadedMediaCompanion(
videoFilePath: Value(filePath),
downloadedAt: Value(DateTime.now().millisecondsSinceEpoch),
),
);
}
/// Update artwork paths
Future<void> updateArtworkPaths({required String globalKey, String? thumbPath}) async {
await (update(
downloadedMedia,
)..where((t) => t.globalKey.equals(globalKey))).write(DownloadedMediaCompanion(thumbPath: Value(thumbPath)));
}
/// Update download error and increment retry count
Future<void> updateDownloadError(String globalKey, String errorMessage) async {
// Get current retry count to increment it
final existing = await getDownloadedMedia(globalKey);
final currentCount = existing?.retryCount ?? 0;
await (update(downloadedMedia)..where((t) => t.globalKey.equals(globalKey))).write(
DownloadedMediaCompanion(errorMessage: Value(errorMessage), retryCount: Value(currentCount + 1)),
);
}
/// Clear download error and reset retry count (for retry)
Future<void> clearDownloadError(String globalKey) async {
await (update(downloadedMedia)..where((t) => t.globalKey.equals(globalKey))).write(
const DownloadedMediaCompanion(errorMessage: Value(null), retryCount: Value(0)),
);
}
/// Remove item from queue
Future<void> removeFromQueue(String mediaGlobalKey) async {
await (delete(downloadQueue)..where((t) => t.mediaGlobalKey.equals(mediaGlobalKey))).go();
}
/// Get downloaded media item
Future<DownloadedMediaItem?> getDownloadedMedia(String globalKey) {
return (select(downloadedMedia)..where((t) => t.globalKey.equals(globalKey))).getSingleOrNull();
}
/// Delete a download
Future<void> deleteDownload(String globalKey) async {
await (delete(downloadedMedia)..where((t) => t.globalKey.equals(globalKey))).go();
await (delete(downloadQueue)..where((t) => t.mediaGlobalKey.equals(globalKey))).go();
}
/// Get all downloaded episodes for a season
Future<List<DownloadedMediaItem>> getEpisodesBySeason(String seasonKey) {
return (select(downloadedMedia)..where((t) => t.parentRatingKey.equals(seasonKey))).get();
}
/// Get all downloaded episodes for a show
Future<List<DownloadedMediaItem>> getEpisodesByShow(String showKey) {
return (select(downloadedMedia)..where((t) => t.grandparentRatingKey.equals(showKey))).get();
}
/// Get all downloaded items for a specific server
Future<List<DownloadedMediaItem>> getDownloadsByServerId(String serverId) {
return (select(downloadedMedia)..where((t) => t.serverId.equals(serverId))).get();
}
/// Update the background_downloader task ID for a download
Future<void> updateBgTaskId(String globalKey, String? taskId) async {
await (update(
downloadedMedia,
)..where((t) => t.globalKey.equals(globalKey))).write(DownloadedMediaCompanion(bgTaskId: Value(taskId)));
}
/// Get the background_downloader task ID for a download
Future<String?> getBgTaskId(String globalKey) async {
final item = await getDownloadedMedia(globalKey);
return item?.bgTaskId;
}
}
+1
View File
@@ -47,6 +47,7 @@ class DownloadedMedia extends Table {
IntColumn get downloadedAt => integer().nullable()();
TextColumn get errorMessage => text().nullable()();
IntColumn get retryCount => integer().withDefault(const Constant(0))();
TextColumn get bgTaskId => text().nullable()();
}
/// Queue for offline watch progress and manual watch actions.
+60 -22
View File
@@ -45,6 +45,11 @@ extension DpadKeyExtension on LogicalKeyboardKey {
/// Whether this key is a context menu key.
bool get isContextMenuKey => _contextMenuKeys.contains(this);
/// Whether this key is a navigation key (dpad, select, back, context menu, tab).
/// Use this to distinguish navigation keys from typing/volume/media keys.
bool get isNavigationKey =>
isDpadDirection || isSelectKey || isBackKey || isContextMenuKey || this == LogicalKeyboardKey.tab;
/// Whether this key moves focus left.
bool get isLeftKey => this == LogicalKeyboardKey.arrowLeft;
@@ -58,32 +63,47 @@ extension DpadKeyExtension on LogicalKeyboardKey {
bool get isDownKey => this == LogicalKeyboardKey.arrowDown;
}
/// Global helper to suppress the next SELECT key-up event.
class SelectKeyUpSuppressor {
static bool _suppressSelectUntilKeyUp = false;
/// Base class for suppressing key-up events after a key category triggers an
/// action (e.g. opening a sheet). While suppressed, all events for the matched
/// key category are consumed; suppression auto-clears on [KeyUpEvent].
class _KeyUpSuppressor {
final bool Function(LogicalKeyboardKey) _keyMatcher;
static void suppressSelectUntilKeyUp() {
_suppressSelectUntilKeyUp = true;
}
_KeyUpSuppressor(this._keyMatcher);
static bool consumeIfSuppressed(KeyEvent event) {
if (!_suppressSelectUntilKeyUp) return false;
if (event.logicalKey.isSelectKey) {
if (event is KeyUpEvent) {
_suppressSelectUntilKeyUp = false;
}
bool _suppressed = false;
void suppress() => _suppressed = true;
void clearSuppression() => _suppressed = false;
/// Returns `true` (consumed) when the event belongs to the matched key
/// category and suppression is active. Clears suppression on [KeyUpEvent].
bool consumeIfSuppressed(KeyEvent event) {
if (!_suppressed) return false;
if (_keyMatcher(event.logicalKey)) {
if (event is KeyUpEvent) _suppressed = false;
return true;
}
return false;
}
}
/// Global helper to suppress the next SELECT key-up event.
class SelectKeyUpSuppressor {
static final _instance = _KeyUpSuppressor((k) => k.isSelectKey);
static void suppressSelectUntilKeyUp() => _instance.suppress();
static void clearSuppression() => _instance.clearSuppression();
static bool consumeIfSuppressed(KeyEvent event) => _instance.consumeIfSuppressed(event);
}
/// Global helper to suppress the next BACK key-up event.
///
/// Use this when a modal (bottom sheet, dialog) closes to prevent
/// the BACK key-up from propagating to the underlying screen.
class BackKeyUpSuppressor {
static bool _suppressBackUntilKeyUp = false;
static final _instance = _KeyUpSuppressor((k) => k.isBackKey);
static bool _closedViaBackKey = false;
/// Mark that a modal is being closed via back key press.
@@ -100,24 +120,42 @@ class BackKeyUpSuppressor {
_closedViaBackKey = false;
return;
}
_suppressBackUntilKeyUp = true;
_instance.suppress();
}
/// Clear any pending suppression. Call when opening a new modal
/// to ensure stale suppression from previous closes doesn't affect it.
static void clearSuppression() {
_suppressBackUntilKeyUp = false;
_instance.clearSuppression();
_closedViaBackKey = false;
}
static bool consumeIfSuppressed(KeyEvent event) {
if (!_suppressBackUntilKeyUp) return false;
static bool consumeIfSuppressed(KeyEvent event) => _instance.consumeIfSuppressed(event);
}
/// Tracks whether a back key is currently physically pressed.
///
/// Used by [BackKeySuppressorObserver] to detect when a route pop was
/// caused by a back key press (e.g. Flutter's built-in DismissAction,
/// DismissAction on KeyRepeat, or Android TV system back gesture) so it
/// can automatically suppress the stray KeyUp that follows.
class BackKeyPressTracker {
static bool _isBackKeyDown = false;
/// Whether a back key is currently held down.
///
/// Also checks [HardwareKeyboard.instance.logicalKeysPressed] as a
/// fallback in case our tracking drifted out of sync.
static bool get isBackKeyDown {
if (_isBackKeyDown) return true;
return HardwareKeyboard.instance.logicalKeysPressed.any((key) => key.isBackKey);
}
static bool handleKeyEvent(KeyEvent event) {
if (event.logicalKey.isBackKey) {
if (event is KeyUpEvent) {
_suppressBackUntilKeyUp = false;
}
return true;
// KeyDown and KeyRepeat both mean the key is physically held.
_isBackKeyDown = event is! KeyUpEvent;
}
return false;
return false; // Never consume
}
}
+2 -1
View File
@@ -29,8 +29,9 @@ class FocusTheme {
BuildContext context, {
required bool isFocused,
double borderRadius = defaultBorderRadius,
Color? color,
}) {
final focusColor = getFocusBorderColor(context);
final focusColor = color ?? getFocusBorderColor(context);
return BoxDecoration(
borderRadius: BorderRadius.circular(borderRadius),
+184
View File
@@ -0,0 +1,184 @@
import 'package:flutter/material.dart';
import '../widgets/app_icon.dart';
import 'focus_theme.dart';
import 'input_mode_tracker.dart';
import 'key_event_utils.dart';
/// Describes a single action button for use in [FocusableActionBar].
class FocusableAction {
/// Icon to display. Ignored when [child] is provided.
final IconData icon;
/// Icon color. Ignored when [child] is provided.
final Color? iconColor;
final String? tooltip;
final VoidCallback? onPressed;
/// Optional custom child widget placed inside the focus container.
/// Overrides the default [IconButton] built from [icon]/[tooltip]/[onPressed].
final Widget? child;
const FocusableAction({
this.icon = Icons.circle,
this.iconColor,
this.tooltip,
this.onPressed,
this.child,
});
}
/// A row of focusable action buttons for app bar [actions:].
///
/// Manages focus nodes, left/right D-pad navigation between buttons,
/// and the standard white-alpha background focus indicator internally.
///
/// Returns a single [Row] widget — place it inside the `actions:` list:
/// ```dart
/// CustomAppBar(
/// title: Text('Title'),
/// actions: [
/// FocusableActionBar(
/// actions: [
/// FocusableAction(icon: Symbols.refresh_rounded, onPressed: _refresh),
/// FocusableAction(icon: Symbols.upload_rounded, onPressed: _upload),
/// ],
/// ),
/// ],
/// )
/// ```
class FocusableActionBar extends StatefulWidget {
final List<FocusableAction> actions;
/// Called when the user presses down from any action button.
final VoidCallback? onNavigateDown;
/// Called when the user presses up from any action button.
final VoidCallback? onNavigateUp;
/// Called when the user presses left from the leftmost button.
final VoidCallback? onNavigateLeft;
/// Called when the user presses right from the rightmost button.
final VoidCallback? onNavigateRight;
/// Called when the user presses the back key while an action is focused.
final VoidCallback? onBack;
const FocusableActionBar({
super.key,
required this.actions,
this.onNavigateDown,
this.onNavigateUp,
this.onNavigateLeft,
this.onNavigateRight,
this.onBack,
});
@override
State<FocusableActionBar> createState() => FocusableActionBarState();
}
class FocusableActionBarState extends State<FocusableActionBar> {
late List<FocusNode> _focusNodes;
late List<bool> _focusStates;
/// Access a focus node by index (e.g. for external `requestFocus()` calls).
FocusNode getFocusNode(int index) => _focusNodes[index];
@override
void initState() {
super.initState();
_initNodes();
}
@override
void didUpdateWidget(FocusableActionBar oldWidget) {
super.didUpdateWidget(oldWidget);
if (oldWidget.actions.length != widget.actions.length) {
_disposeNodes();
_initNodes();
}
}
void _initNodes() {
_focusNodes = List.generate(widget.actions.length, (i) => FocusNode(debugLabel: 'ActionBar[$i]'));
_focusStates = List.filled(widget.actions.length, false);
for (var i = 0; i < _focusNodes.length; i++) {
final idx = i;
_focusNodes[i].addListener(() {
final hasFocus = _focusNodes[idx].hasFocus;
if (_focusStates[idx] != hasFocus) {
setState(() => _focusStates[idx] = hasFocus);
}
});
}
}
void _disposeNodes() {
for (final node in _focusNodes) {
node.dispose();
}
}
@override
void dispose() {
_disposeNodes();
super.dispose();
}
@override
Widget build(BuildContext context) {
final isKeyboard = InputModeTracker.isKeyboardMode(context);
final duration = FocusTheme.getAnimationDuration(context);
return Row(
mainAxisSize: MainAxisSize.min,
children: [
for (var i = 0; i < widget.actions.length; i++) _buildButton(i, isKeyboard, duration),
],
);
}
Widget _buildButton(int index, bool isKeyboard, Duration duration) {
final action = widget.actions[index];
final isFocused = _focusStates[index];
final showFocus = isFocused && isKeyboard;
final opacity = isKeyboard && !isFocused ? 0.6 : 1.0;
return Focus(
focusNode: _focusNodes[index],
onKeyEvent: (node, event) {
if (widget.onBack != null) {
final backResult = handleBackKeyAction(event, widget.onBack!);
if (backResult != KeyEventResult.ignored) return backResult;
}
return dpadKeyHandler(
onSelect: action.onPressed,
onLeft: index > 0
? () => _focusNodes[index - 1].requestFocus()
: widget.onNavigateLeft,
onRight: index < _focusNodes.length - 1
? () => _focusNodes[index + 1].requestFocus()
: widget.onNavigateRight,
onDown: widget.onNavigateDown,
onUp: widget.onNavigateUp,
)(node, event);
},
child: AnimatedOpacity(
opacity: showFocus ? 1.0 : opacity,
duration: duration,
child: Container(
decoration: FocusTheme.focusBackgroundDecoration(isFocused: showFocus, borderRadius: 20),
child: action.child ??
IconButton(
icon: AppIcon(action.icon, fill: 1, color: action.iconColor),
tooltip: action.tooltip,
onPressed: action.onPressed,
),
),
),
);
}
}
+95
View File
@@ -0,0 +1,95 @@
import 'package:flutter/material.dart';
import 'focus_theme.dart';
import 'focusable_wrapper.dart';
import 'input_mode_tracker.dart';
/// A focusable button wrapper for D-pad navigation on TV.
///
/// Wraps any button widget with [FocusableWrapper] and adds a white overlay
/// + contrasting border when focused. Tracks focus state internally so callers
/// don't need manual state management.
///
/// ```dart
/// FocusableButton(
/// autofocus: true,
/// onPressed: _doSomething,
/// child: FilledButton.icon(
/// onPressed: _doSomething,
/// icon: Icon(Symbols.add_rounded),
/// label: Text('Create'),
/// ),
/// )
/// ```
class FocusableButton extends StatefulWidget {
final Widget child;
final VoidCallback? onPressed;
final bool autofocus;
final FocusNode? focusNode;
/// Navigation callbacks for explicit focus control (e.g. horizontal button rows).
final VoidCallback? onNavigateUp;
final VoidCallback? onNavigateDown;
final VoidCallback? onNavigateLeft;
final VoidCallback? onNavigateRight;
final VoidCallback? onBack;
/// Whether to scroll the widget into view when focused.
final bool autoScroll;
/// Whether to use background color instead of border for focus indicator.
final bool useBackgroundFocus;
const FocusableButton({
super.key,
required this.child,
this.onPressed,
this.autofocus = false,
this.focusNode,
this.onNavigateUp,
this.onNavigateDown,
this.onNavigateLeft,
this.onNavigateRight,
this.onBack,
this.autoScroll = true,
this.useBackgroundFocus = false,
});
@override
State<FocusableButton> createState() => _FocusableButtonState();
}
class _FocusableButtonState extends State<FocusableButton> {
bool _isFocused = false;
@override
Widget build(BuildContext context) {
final isKeyboard = InputModeTracker.isKeyboardMode(context);
final showFocus = _isFocused && isKeyboard;
final duration = FocusTheme.getAnimationDuration(context);
// In dpad mode: focused = full opacity, unfocused = dimmed
final opacity = isKeyboard && !_isFocused ? 0.6 : 1.0;
return FocusableWrapper(
autofocus: widget.autofocus,
focusNode: widget.focusNode,
disableScale: true,
borderRadius: 100,
useBackgroundFocus: widget.useBackgroundFocus,
descendantsAreFocusable: false,
onFocusChange: (f) => setState(() => _isFocused = f),
autoScroll: widget.autoScroll,
onSelect: widget.onPressed,
onNavigateUp: widget.onNavigateUp,
onNavigateDown: widget.onNavigateDown,
onNavigateLeft: widget.onNavigateLeft,
onNavigateRight: widget.onNavigateRight,
onBack: widget.onBack,
child: AnimatedOpacity(
opacity: showFocus ? 1.0 : opacity,
duration: duration,
child: widget.child,
),
);
}
}
+55 -8
View File
@@ -1,13 +1,19 @@
import 'dart:async';
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
import 'dpad_navigator.dart';
import 'key_event_utils.dart';
/// Callbacks for chip key event handling.
class ChipKeyCallbacks {
/// Called when SELECT key is pressed.
/// Called when SELECT key is pressed (short press when [onLongPress] is set).
final VoidCallback? onSelect;
/// Called when SELECT key is held for 500ms.
final VoidCallback? onLongPress;
/// Called when DOWN arrow is pressed.
final VoidCallback? onNavigateDown;
@@ -25,6 +31,7 @@ class ChipKeyCallbacks {
const ChipKeyCallbacks({
this.onSelect,
this.onLongPress,
this.onNavigateDown,
this.onNavigateUp,
this.onNavigateLeft,
@@ -53,6 +60,8 @@ class ChipKeyCallbacks {
mixin FocusableChipStateMixin<T extends StatefulWidget> on State<T> {
FocusNode? _internalFocusNode;
bool _isFocused = false;
Timer? _longPressTimer;
bool _isSelectKeyDown = false;
/// Override to return the widget's optional external focus node.
FocusNode? get widgetFocusNode;
@@ -85,6 +94,7 @@ mixin FocusableChipStateMixin<T extends StatefulWidget> on State<T> {
void disposeFocusNode() {
focusNode.removeListener(_onFocusChange);
_internalFocusNode?.dispose();
_longPressTimer?.cancel();
}
void _onFocusChange() {
@@ -96,13 +106,13 @@ mixin FocusableChipStateMixin<T extends StatefulWidget> on State<T> {
/// Shared key event handler for chip widgets.
///
/// Handles common key patterns:
/// - SELECT key -> onSelect
/// - SELECT key -> onSelect (short press) / onLongPress (hold 500ms)
/// - Arrow keys -> navigation callbacks
/// - BACK key -> onBack
///
/// Returns [KeyEventResult.handled] if the event was consumed,
/// [KeyEventResult.ignored] otherwise.
KeyEventResult handleChipKeyEvent(FocusNode node, KeyEvent event, ChipKeyCallbacks callbacks) {
KeyEventResult handleChipKeyEvent(FocusNode _, KeyEvent event, ChipKeyCallbacks callbacks) {
final key = event.logicalKey;
if (callbacks.onBack != null) {
@@ -112,16 +122,53 @@ mixin FocusableChipStateMixin<T extends StatefulWidget> on State<T> {
}
}
if (!event.isActionable) {
return KeyEventResult.ignored;
if (SelectKeyUpSuppressor.consumeIfSuppressed(event)) {
return KeyEventResult.handled;
}
// SELECT key activates the chip
if (key.isSelectKey && callbacks.onSelect != null) {
callbacks.onSelect!();
// SELECT key with long press support
if (key.isSelectKey) {
if (callbacks.onLongPress != null) {
if (event is KeyDownEvent) {
if (!_isSelectKeyDown) {
_isSelectKeyDown = true;
_longPressTimer?.cancel();
_longPressTimer = Timer(const Duration(milliseconds: 500), () {
if (mounted) {
SelectKeyUpSuppressor.suppressSelectUntilKeyUp();
callbacks.onLongPress?.call();
}
});
}
return KeyEventResult.handled;
} else if (event is KeyRepeatEvent) {
return KeyEventResult.handled;
} else if (event is KeyUpEvent) {
final timerWasActive = _longPressTimer?.isActive ?? false;
_longPressTimer?.cancel();
if (timerWasActive && _isSelectKeyDown) {
callbacks.onSelect?.call();
}
_isSelectKeyDown = false;
return KeyEventResult.handled;
}
} else if (event.isActionable && callbacks.onSelect != null) {
callbacks.onSelect!();
return KeyEventResult.handled;
}
}
// Context menu key triggers long press directly
if (event.isActionable && key.isContextMenuKey && callbacks.onLongPress != null) {
SelectKeyUpSuppressor.suppressSelectUntilKeyUp();
callbacks.onLongPress!();
return KeyEventResult.handled;
}
if (!event.isActionable) {
return KeyEventResult.ignored;
}
// LEFT arrow - call callback if provided, otherwise propagate to parent
if (key.isLeftKey) {
if (callbacks.onNavigateLeft != null) {
+32 -2
View File
@@ -33,6 +33,9 @@ class FocusableWrapper extends StatefulWidget {
/// Called when the user presses UP and there's no focusable item above.
final VoidCallback? onNavigateUp;
/// Called when the user presses DOWN and there's no focusable item below.
final VoidCallback? onNavigateDown;
/// Called when the user presses LEFT and there's no focusable item to the left.
final VoidCallback? onNavigateLeft;
@@ -83,10 +86,19 @@ class FocusableWrapper extends StatefulWidget {
/// Useful for video controls where outline doesn't look good.
final bool useBackgroundFocus;
/// Custom color for the focus border. Only used when [useBackgroundFocus] is false.
/// Useful for filled buttons where the default primary border blends in.
final Color? focusColor;
/// Whether to disable the scale animation on focus.
/// Useful for elements like sliders where scaling looks odd.
final bool disableScale;
/// Whether descendants can receive focus.
/// Set to false when the child widget has its own Focus (e.g. buttons)
/// that would compete with this wrapper's focus handling.
final bool descendantsAreFocusable;
const FocusableWrapper({
super.key,
required this.child,
@@ -94,6 +106,7 @@ class FocusableWrapper extends StatefulWidget {
this.onLongPress,
this.onFocusChange,
this.onNavigateUp,
this.onNavigateDown,
this.onNavigateLeft,
this.onNavigateRight,
this.onBack,
@@ -109,7 +122,9 @@ class FocusableWrapper extends StatefulWidget {
this.enableLongPress = false,
this.longPressDuration = const Duration(milliseconds: 500),
this.useBackgroundFocus = false,
this.focusColor,
this.disableScale = false,
this.descendantsAreFocusable = true,
});
@override
@@ -225,7 +240,15 @@ class _FocusableWrapperState extends State<FocusableWrapper> with SingleTickerPr
final renderObject = context.findRenderObject();
if (renderObject == null) return;
final scrollable = Scrollable.maybeOf(context);
// Find the nearest scrollable that actually has scroll range.
// Skip inner scrollables with no extent (e.g. shrinkWrap ListView
// with NeverScrollableScrollPhysics inside an outer scroll view).
var scrollable = Scrollable.maybeOf(context);
while (scrollable != null) {
final pos = scrollable.position;
if (pos.maxScrollExtent > pos.minScrollExtent) break;
scrollable = Scrollable.maybeOf(scrollable.context);
}
if (scrollable == null) return;
final viewport = scrollable.context.findRenderObject() as RenderBox?;
@@ -367,6 +390,12 @@ class _FocusableWrapperState extends State<FocusableWrapper> with SingleTickerPr
return KeyEventResult.handled;
}
// DOWN arrow - if callback provided, navigate down
if (key == LogicalKeyboardKey.arrowDown && widget.onNavigateDown != null) {
widget.onNavigateDown!();
return KeyEventResult.handled;
}
// LEFT arrow - if callback provided, navigate left (caller is responsible
// for only providing this callback when the item is at the left edge)
if (key == LogicalKeyboardKey.arrowLeft && widget.onNavigateLeft != null) {
@@ -398,11 +427,12 @@ class _FocusableWrapperState extends State<FocusableWrapper> with SingleTickerPr
// Choose decoration based on useBackgroundFocus
final decoration = widget.useBackgroundFocus
? FocusTheme.focusBackgroundDecoration(isFocused: showFocus, borderRadius: widget.borderRadius)
: FocusTheme.focusDecoration(context, isFocused: showFocus, borderRadius: widget.borderRadius);
: FocusTheme.focusDecoration(context, isFocused: showFocus, borderRadius: widget.borderRadius, color: widget.focusColor);
Widget result = Focus(
focusNode: _focusNode,
autofocus: widget.autofocus,
descendantsAreFocusable: widget.descendantsAreFocusable,
onFocusChange: _handleFocusChange,
onKeyEvent: _handleKeyEvent,
child: AnimatedBuilder(
+20 -3
View File
@@ -3,6 +3,8 @@ import 'package:flutter/services.dart';
import '../utils/platform_detector.dart';
import '../services/gamepad_service.dart';
import 'dpad_navigator.dart';
import '../services/companion_remote/companion_remote_receiver.dart';
/// Tracks whether the user is navigating via keyboard/d-pad or pointer (mouse/touch).
///
@@ -56,18 +58,27 @@ class _InputModeTrackerState extends State<InputModeTracker> {
// Register callback for gamepad input to switch to keyboard mode
GamepadService.onGamepadInput = () => _setMode(InputMode.keyboard);
// Register callback for companion remote input to switch to keyboard mode
CompanionRemoteReceiver.onRemoteInput = () => _setMode(InputMode.keyboard);
}
@override
void dispose() {
HardwareKeyboard.instance.removeHandler(_handleKeyEvent);
GamepadService.onGamepadInput = null;
CompanionRemoteReceiver.onRemoteInput = null;
super.dispose();
}
bool _handleKeyEvent(KeyEvent event) {
// Only switch to keyboard mode on key down (not repeats or releases)
if (event is KeyDownEvent) {
// Track back key press state for automatic suppression of stray KeyUp
// events after route pops (see BackKeySuppressorObserver).
BackKeyPressTracker.handleKeyEvent(event);
// Only switch to keyboard mode on navigation key down (not repeats, releases,
// or non-navigation keys like volume buttons or letter keys while typing)
if (event is KeyDownEvent && event.logicalKey.isNavigationKey) {
_setMode(InputMode.keyboard);
}
// Return false to let the event continue propagating
@@ -107,7 +118,13 @@ class _InputModeTrackerState extends State<InputModeTracker> {
onPointerDown: (_) => _setMode(InputMode.pointer),
onPointerHover: (_) => _setMode(InputMode.pointer),
behavior: HitTestBehavior.translucent,
child: _InputModeProvider(mode: _mode, child: widget.child),
child: MouseRegion(
cursor: _mode == InputMode.keyboard ? SystemMouseCursors.none : MouseCursor.defer,
child: IgnorePointer(
ignoring: _mode == InputMode.keyboard,
child: _InputModeProvider(mode: _mode, child: widget.child),
),
),
);
}
}
+71
View File
@@ -82,3 +82,74 @@ KeyEventResult handleBackKeyNavigation<T>(BuildContext context, KeyEvent event,
// (KeyDownEvent can be received by both the popping screen and the returned-to screen)
return handleBackKeyAction(event, () => Navigator.pop(context, result));
}
/// Creates a [FocusOnKeyEventCallback] that dispatches d-pad / arrow keys to
/// the provided directional callbacks.
///
/// Each callback is optional. Directions without a callback are ignored
/// (passed through to the framework). Directions mapped to a callback
/// automatically return [KeyEventResult.handled].
///
/// Only [KeyDownEvent] and [KeyRepeatEvent] are handled (via [isActionable]).
///
/// ```dart
/// Focus(
/// onKeyEvent: dpadKeyHandler(
/// onUp: () => _focusAppBar(),
/// onDown: () => _focusContent(),
/// onLeft: () => _navigateToSidebar(),
/// onSelect: () => _play(),
/// ),
/// child: ...
/// )
/// ```
FocusOnKeyEventCallback dpadKeyHandler({
VoidCallback? onUp,
VoidCallback? onDown,
VoidCallback? onLeft,
VoidCallback? onRight,
VoidCallback? onSelect,
}) {
return (FocusNode _, KeyEvent event) {
if (!event.isActionable) return KeyEventResult.ignored;
final key = event.logicalKey;
if (key.isUpKey && onUp != null) {
onUp();
return KeyEventResult.handled;
}
if (key.isDownKey && onDown != null) {
onDown();
return KeyEventResult.handled;
}
if (key.isLeftKey && onLeft != null) {
onLeft();
return KeyEventResult.handled;
}
if (key.isRightKey && onRight != null) {
onRight();
return KeyEventResult.handled;
}
if (key.isSelectKey && onSelect != null) {
onSelect();
return KeyEventResult.handled;
}
return KeyEventResult.ignored;
};
}
/// Navigator observer that automatically suppresses stray back KeyUp events
/// after any route pop caused by a back key press.
///
/// This catches pops triggered by Flutter's built-in DismissAction (which fires
/// on KeyDown for dialogs) and Android TV system back gestures, preventing the
/// orphaned KeyUp from propagating to the underlying screen's back handler.
class BackKeySuppressorObserver extends NavigatorObserver {
@override
void didPop(Route route, Route? previousRoute) {
if (BackKeyPressTracker.isBackKeyDown) {
BackKeyUpSuppressor.suppressBackUntilKeyUp();
}
}
}
+502
View File
@@ -0,0 +1,502 @@
{
"app": { "title": "Plezy" },
"auth": {
"signInWithPlex": "Log ind med Plex",
"showQRCode": "Vis QR-kode",
"authenticate": "Godkend",
"authenticationTimeout": "Godkendelse fik timeout. Prøv igen.",
"scanQRToSignIn": "Scan denne QR-kode for at logge ind",
"waitingForAuth": "Venter på godkendelse...\nFærdiggør login i din browser.",
"useBrowser": "Brug browser"
},
"common": {
"cancel": "Annuller", "save": "Gem", "close": "Luk", "clear": "Ryd", "reset": "Nulstil",
"later": "Senere", "submit": "Indsend", "confirm": "Bekræft", "retry": "Prøv igen",
"logout": "Log ud", "unknown": "Ukendt", "refresh": "Opdater", "yes": "Ja", "no": "Nej",
"delete": "Slet", "shuffle": "Bland", "addTo": "Tilføj til...", "createNew": "Opret ny",
"remove": "Fjern", "paste": "Indsæt", "connect": "Forbind", "disconnect": "Afbryd",
"play": "Afspil", "pause": "Pause", "resume": "Genoptag", "error": "Fejl",
"search": "Søg", "home": "Hjem", "back": "Tilbage", "settings": "Indstillinger",
"mute": "Lydløs", "ok": "OK", "loading": "Indlæser...", "reconnect": "Genopret forbindelse",
"exitConfirmTitle": "Luk app?", "exitConfirmMessage": "Er du sikker på, at du vil afslutte?",
"dontAskAgain": "Spørg ikke igen", "exit": "Afslut", "viewAll": "Vis alle",
"checkingNetwork": "Tjekker netværk...", "refreshingServers": "Opdaterer servere...",
"loadingServers": "Indlæser servere...", "connectingToServers": "Forbinder til servere...",
"startingOfflineMode": "Starter offlinetilstand..."
},
"screens": { "licenses": "Licenser", "switchProfile": "Skift profil", "subtitleStyling": "Undertekststil", "mpvConfig": "mpv.conf", "logs": "Logs" },
"update": {
"available": "Opdatering tilgængelig", "versionAvailable": "Version ${version} er tilgængelig",
"currentVersion": "Nuværende: ${version}", "skipVersion": "Spring denne version over",
"viewRelease": "Vis udgivelse", "latestVersion": "Du har den nyeste version",
"checkFailed": "Kunne ikke søge efter opdateringer"
},
"settings": {
"title": "Indstillinger", "language": "Sprog", "theme": "Tema", "appearance": "Udseende",
"videoPlayback": "Videoafspilning", "advanced": "Avanceret",
"episodePosterMode": "Episodeplakatstil", "seriesPoster": "Serieplakat",
"seriesPosterDescription": "Vis seriens plakat for alle episoder",
"seasonPoster": "Sæsonplakat", "seasonPosterDescription": "Vis sæsonspecifik plakat for episoder",
"episodeThumbnail": "Episodeminiature", "episodeThumbnailDescription": "Vis 16:9 episodeskærmbilledeminiaturer",
"showHeroSectionDescription": "Vis karrusel med udvalgt indhold på startskærmen",
"secondsLabel": "Sekunder", "minutesLabel": "Minutter", "secondsShort": "s", "minutesShort": "m",
"durationHint": "Indtast varighed (${min}-${max})",
"systemTheme": "System", "systemThemeDescription": "Følg systemindstillinger",
"lightTheme": "Lys", "darkTheme": "Mørk", "oledTheme": "OLED", "oledThemeDescription": "Ren sort for OLED-skærme",
"libraryDensity": "Bibliotekstæthed", "compact": "Kompakt", "compactDescription": "Mindre kort, flere synlige elementer",
"normal": "Normal", "normalDescription": "Standardstørrelse",
"comfortable": "Komfortabel", "comfortableDescription": "Større kort, færre synlige elementer",
"viewMode": "Visningstilstand", "gridView": "Gitter", "gridViewDescription": "Vis elementer i gitterlayout",
"listView": "Liste", "listViewDescription": "Vis elementer i listelayout",
"showHeroSection": "Vis hero-sektion", "useGlobalHubs": "Brug Plex Home-layout",
"useGlobalHubsDescription": "Vis startsidehubbe som den officielle Plex-klient. Når slået fra, vises anbefalinger per bibliotek.",
"showServerNameOnHubs": "Vis servernavn på hubbe",
"showServerNameOnHubsDescription": "Vis altid servernavnet i hubtitler. Når slået fra, vises kun ved duplikerede navne.",
"alwaysKeepSidebarOpen": "Hold altid sidepanelet åbent",
"alwaysKeepSidebarOpenDescription": "Sidepanelet forbliver udvidet, og indholdsområdet tilpasser sig",
"showUnwatchedCount": "Vis antal usete",
"showUnwatchedCountDescription": "Vis antal usete episoder på serier og sæsoner",
"hideSpoilers": "Skjul spoilere for usete episoder",
"hideSpoilersDescription": "Slør miniaturebilleder og skjul beskrivelser for episoder, du ikke har set endnu",
"playerBackend": "Afspillerbackend", "exoPlayer": "ExoPlayer (Anbefalet)",
"exoPlayerDescription": "Android-native afspiller med bedre hardwareunderstøttelse",
"mpv": "mpv", "mpvDescription": "Avanceret afspiller med flere funktioner og ASS-undertekstunderstøttelse",
"hardwareDecoding": "Hardwaredekodning", "hardwareDecodingDescription": "Brug hardwareacceleration når tilgængelig",
"bufferSize": "Bufferstørrelse", "bufferSizeMB": "${size}MB", "bufferSizeAuto": "Auto (Anbefalet)",
"bufferSizeWarning": "Din enhed har ${heap}MB hukommelse. En buffer på ${size}MB kan forårsage afspilningsproblemer.",
"subtitleStyling": "Undertekststil", "subtitleStylingDescription": "Tilpas underteksters udseende",
"smallSkipDuration": "Kort spring-varighed", "largeSkipDuration": "Lang spring-varighed",
"secondsUnit": "${seconds} sekunder", "defaultSleepTimer": "Standard sove-timer",
"minutesUnit": "${minutes} minutter",
"rememberTrackSelections": "Husk sporvalg per serie/film",
"rememberTrackSelectionsDescription": "Gem automatisk lyd- og undertekstsprogpræferencer når du skifter spor under afspilning",
"clickVideoTogglesPlayback": "Klik på video skifter afspil/pause",
"clickVideoTogglesPlaybackDescription": "Når aktiveret, afspiller/pauser klik på videoen. Ellers vises/skjules betjeningselementer.",
"videoPlayerControls": "Videoafspillerkontroller", "keyboardShortcuts": "Tastaturgenveje",
"keyboardShortcutsDescription": "Tilpas tastaturgenveje",
"videoPlayerNavigation": "Videoafspillernavigation",
"videoPlayerNavigationDescription": "Brug piletaster til at navigere videoafspillerkontroller",
"crashReporting": "Fejlrapportering", "crashReportingDescription": "Send fejlrapporter for at hjælpe med at forbedre appen",
"debugLogging": "Fejlfindingslogning", "debugLoggingDescription": "Aktiver detaljeret logning til fejlfinding",
"viewLogs": "Vis logs", "viewLogsDescription": "Vis applikationslogs",
"clearCache": "Ryd cache",
"clearCacheDescription": "Dette rydder alle cachelagrede billeder og data. Appen kan tage længere tid om at indlæse indhold efter rydning.",
"clearCacheSuccess": "Cache ryddet", "resetSettings": "Nulstil indstillinger",
"resetSettingsDescription": "Alle indstillinger nulstilles til standardværdier. Denne handling kan ikke fortrydes.",
"resetSettingsSuccess": "Indstillinger nulstillet", "shortcutsReset": "Genveje nulstillet til standard",
"about": "Om", "aboutDescription": "App-information og licenser",
"updates": "Opdateringer", "updateAvailable": "Opdatering tilgængelig",
"checkForUpdates": "Søg efter opdateringer",
"validationErrorEnterNumber": "Indtast et gyldigt tal",
"validationErrorDuration": "Varighed skal være mellem ${min} og ${max} ${unit}",
"shortcutAlreadyAssigned": "Genvej allerede tildelt til ${action}",
"shortcutUpdated": "Genvej opdateret for ${action}",
"autoSkip": "Auto-spring", "autoSkipIntro": "Auto-spring intro",
"autoSkipIntroDescription": "Spring automatisk intromarkører over efter få sekunder",
"autoSkipCredits": "Auto-spring rulletekster",
"autoSkipCreditsDescription": "Spring automatisk rulletekster over og afspil næste episode",
"autoSkipDelay": "Auto-spring forsinkelse",
"autoSkipDelayDescription": "Vent ${seconds} sekunder før automatisk spring",
"introPattern": "Intromarkørmønster",
"introPatternDescription": "Regulært udtryk til at genkende intromarkører i kapiteltitler",
"creditsPattern": "Rulletekstmarkørmønster",
"creditsPatternDescription": "Regulært udtryk til at genkende rulletekstmarkører i kapiteltitler",
"invalidRegex": "Ugyldigt regulært udtryk",
"downloads": "Downloads", "downloadLocationDescription": "Vælg hvor downloadet indhold skal gemmes",
"downloadLocationDefault": "Standard (App-lagring)", "downloadLocationCustom": "Brugerdefineret placering",
"selectFolder": "Vælg mappe", "resetToDefault": "Nulstil til standard",
"currentPath": "Nuværende: ${path}", "downloadLocationChanged": "Downloadplacering ændret",
"downloadLocationReset": "Downloadplacering nulstillet",
"downloadLocationInvalid": "Valgt mappe er ikke skrivbar",
"downloadLocationSelectError": "Kunne ikke vælge mappe",
"downloadOnWifiOnly": "Download kun på WiFi",
"downloadOnWifiOnlyDescription": "Forhindre downloads på mobildata",
"cellularDownloadBlocked": "Downloads er deaktiveret på mobildata. Opret forbindelse til WiFi eller ændr indstillingen.",
"maxVolume": "Maksimal lydstyrke",
"maxVolumeDescription": "Tillad lydstyrkeforstærkning over 100% for stille medier",
"maxVolumePercent": "${percent}%",
"discordRichPresence": "Discord Rich Presence",
"discordRichPresenceDescription": "Vis hvad du ser på Discord",
"autoPip": "Auto billede-i-billede",
"autoPipDescription": "Gå automatisk til billede-i-billede når du forlader appen under afspilning",
"matchContentFrameRate": "Match indholdets billedhastighed",
"matchContentFrameRateDescription": "Juster skærmens opdateringshastighed til videoindhold for at reducere hakken og spare batteri",
"tunneledPlayback": "Tunneleret afspilning",
"tunneledPlaybackDescription": "Brug hardwareaccelereret videotunneling. Deaktiver hvis du ser sort skærm med lyd på HDR-indhold",
"requireProfileSelectionOnOpen": "Spørg om profil ved åbning",
"requireProfileSelectionOnOpenDescription": "Vis profilvalg hver gang appen åbnes",
"confirmExitOnBack": "Bekræft før lukning",
"confirmExitOnBackDescription": "Vis bekræftelsesdialog ved tryk på tilbage for at lukke appen",
"showNavBarLabels": "Vis navigationsbarlabels",
"showNavBarLabelsDescription": "Vis tekstlabels under navigationsbarikoner"
},
"search": {
"hint": "Søg film, serier, musik...", "tryDifferentTerm": "Prøv en anden søgning",
"searchYourMedia": "Søg i dine medier", "enterTitleActorOrKeyword": "Indtast titel, skuespiller eller nøgleord"
},
"hotkeys": {
"setShortcutFor": "Indstil genvej for ${actionName}", "clearShortcut": "Ryd genvej",
"actions": {
"playPause": "Afspil/Pause", "volumeUp": "Lydstyrke op", "volumeDown": "Lydstyrke ned",
"seekForward": "Spol frem (${seconds}s)", "seekBackward": "Spol tilbage (${seconds}s)",
"fullscreenToggle": "Skift fuldskærm", "muteToggle": "Skift lydløs",
"subtitleToggle": "Skift undertekster", "audioTrackNext": "Næste lydspor",
"subtitleTrackNext": "Næste undertekstspor", "chapterNext": "Næste kapitel",
"chapterPrevious": "Forrige kapitel", "speedIncrease": "Øg hastighed",
"speedDecrease": "Sænk hastighed", "speedReset": "Nulstil hastighed",
"subSeekNext": "Søg til næste undertekst", "subSeekPrev": "Søg til forrige undertekst",
"shaderToggle": "Skift shadere", "skipMarker": "Spring intro/rulletekster over"
}
},
"pinEntry": { "enterPin": "Indtast PIN", "showPin": "Vis PIN", "hidePin": "Skjul PIN" },
"fileInfo": {
"title": "Filinfo", "video": "Video", "audio": "Lyd", "file": "Fil", "advanced": "Avanceret",
"codec": "Codec", "resolution": "Opløsning", "bitrate": "Bitrate", "frameRate": "Billedhastighed",
"aspectRatio": "Billedformat", "profile": "Profil", "bitDepth": "Bitdybde",
"colorSpace": "Farverum", "colorRange": "Farveområde", "colorPrimaries": "Farveprimærer",
"chromaSubsampling": "Chroma-subsampling", "channels": "Kanaler", "path": "Sti",
"size": "Størrelse", "container": "Container", "duration": "Varighed",
"optimizedForStreaming": "Optimeret til streaming", "has64bitOffsets": "64-bit offsets"
},
"mediaMenu": {
"markAsWatched": "Markér som set", "markAsUnwatched": "Markér som uset",
"removeFromContinueWatching": "Fjern fra Fortsæt med at se",
"goToSeries": "Gå til serie", "goToSeason": "Gå til sæson",
"shufflePlay": "Afspil tilfældigt", "fileInfo": "Filinfo",
"deleteFromServer": "Slet fra server",
"confirmDelete": "Dette sletter permanent disse medier og filer fra din server. Dette kan ikke fortrydes.",
"deleteMultipleWarning": "Dette inkluderer alle episoder og deres filer.",
"mediaDeletedSuccessfully": "Medieelement slettet", "mediaFailedToDelete": "Kunne ikke slette medieelement",
"rate": "Bedøm"
},
"accessibility": {
"mediaCardMovie": "${title}, film", "mediaCardShow": "${title}, TV-serie",
"mediaCardEpisode": "${title}, ${episodeInfo}", "mediaCardSeason": "${title}, ${seasonInfo}",
"mediaCardWatched": "set", "mediaCardPartiallyWatched": "${percent} procent set",
"mediaCardUnwatched": "uset", "tapToPlay": "Tryk for at afspille"
},
"tooltips": {
"shufflePlay": "Afspil tilfældigt", "playTrailer": "Afspil trailer",
"markAsWatched": "Markér som set", "markAsUnwatched": "Markér som uset"
},
"videoControls": {
"audioLabel": "Lyd", "subtitlesLabel": "Undertekster", "resetToZero": "Nulstil til 0ms",
"addTime": "+${amount}${unit}", "minusTime": "-${amount}${unit}",
"playsLater": "${label} afspilles senere", "playsEarlier": "${label} afspilles tidligere",
"noOffset": "Ingen forskydning", "letterbox": "Letterbox", "fillScreen": "Fyld skærm",
"stretch": "Stræk", "lockRotation": "Lås rotation", "unlockRotation": "Lås rotation op",
"timerActive": "Timer aktiv", "playbackWillPauseIn": "Afspilning pauses om ${duration}",
"sleepTimerCompleted": "Sove-timer fuldført — afspilning sat på pause",
"stillWatching": "Ser du stadig?", "pausingIn": "Pauser om ${seconds}s",
"continueWatching": "Fortsæt", "autoPlayNext": "Auto-afspil næste", "playNext": "Afspil næste",
"playButton": "Afspil", "pauseButton": "Pause",
"seekBackwardButton": "Spol ${seconds} sekunder tilbage",
"seekForwardButton": "Spol ${seconds} sekunder frem",
"previousButton": "Forrige episode", "nextButton": "Næste episode",
"previousChapterButton": "Forrige kapitel", "nextChapterButton": "Næste kapitel",
"muteButton": "Lydløs", "unmuteButton": "Slå lyd til", "settingsButton": "Videoindstillinger",
"audioTrackButton": "Lydspor", "subtitlesButton": "Undertekster",
"tracksButton": "Lyd og undertekster", "chaptersButton": "Kapitler",
"versionsButton": "Videoversioner", "pipButton": "Billede-i-billede-tilstand",
"aspectRatioButton": "Billedformat", "ambientLighting": "Omgivelsesbelysning",
"ambientLightingOn": "Aktivér omgivelsesbelysning", "ambientLightingOff": "Deaktivér omgivelsesbelysning",
"fullscreenButton": "Fuldskærm", "exitFullscreenButton": "Forlad fuldskærm",
"alwaysOnTopButton": "Altid øverst", "rotationLockButton": "Rotationslås",
"timelineSlider": "Videotidslinje", "volumeSlider": "Lydstyrkeniveau",
"endsAt": "Slutter kl. ${time}", "pipActive": "Afspiller i billede-i-billede",
"pipFailed": "Billede-i-billede kunne ikke starte",
"pipErrors": {
"androidVersion": "Kræver Android 8.0 eller nyere", "iosVersion": "Kræver iOS 15.0 eller nyere",
"permissionDisabled": "Billede-i-billede-tilladelse er deaktiveret. Aktivér i Indstillinger > Apps > Plezy > Billede-i-billede",
"notSupported": "Enheden understøtter ikke billede-i-billede",
"voSwitchFailed": "Kunne ikke skifte videooutput til billede-i-billede",
"failed": "Billede-i-billede kunne ikke starte", "unknown": "Der opstod en fejl: ${error}"
},
"chapters": "Kapitler", "noChaptersAvailable": "Ingen kapitler tilgængelige",
"queue": "Kø", "noQueueItems": "Ingen elementer i køen"
},
"userStatus": { "admin": "Administrator", "restricted": "Begrænset", "protected": "Beskyttet", "current": "NUVÆRENDE" },
"messages": {
"markedAsWatched": "Markeret som set", "markedAsUnwatched": "Markeret som uset",
"markedAsWatchedOffline": "Markeret som set (synkroniseres online)",
"markedAsUnwatchedOffline": "Markeret som uset (synkroniseres online)",
"removedFromContinueWatching": "Fjernet fra Fortsæt med at se",
"errorLoading": "Fejl: ${error}", "fileInfoNotAvailable": "Filinfo ikke tilgængelig",
"errorLoadingFileInfo": "Fejl ved indlæsning af filinfo: ${error}",
"errorLoadingSeries": "Fejl ved indlæsning af serie", "errorLoadingSeason": "Fejl ved indlæsning af sæson",
"musicNotSupported": "Musikafspilning understøttes endnu ikke",
"logsCleared": "Logs ryddet", "logsCopied": "Logs kopieret til udklipsholder",
"noLogsAvailable": "Ingen logs tilgængelige",
"libraryScanning": "Scanner \"${title}\"...",
"libraryScanStarted": "Biblioteksscanning startet for \"${title}\"",
"libraryScanFailed": "Kunne ikke scanne bibliotek: ${error}",
"metadataRefreshing": "Opdaterer metadata for \"${title}\"...",
"metadataRefreshStarted": "Metadataopdatering startet for \"${title}\"",
"metadataRefreshFailed": "Kunne ikke opdatere metadata: ${error}",
"logoutConfirm": "Er du sikker på, at du vil logge ud?",
"noSeasonsFound": "Ingen sæsoner fundet", "noEpisodesFound": "Ingen episoder fundet i første sæson",
"noEpisodesFoundGeneral": "Ingen episoder fundet", "noResultsFound": "Ingen resultater fundet",
"sleepTimerSet": "Sove-timer indstillet til ${label}", "noItemsAvailable": "Ingen elementer tilgængelige",
"failedToCreatePlayQueueNoItems": "Kunne ikke oprette afspilningskø — ingen elementer",
"failedPlayback": "Kunne ikke ${action}: ${error}",
"switchingToCompatiblePlayer": "Skifter til kompatibel afspiller...",
"logsUploaded": "Logs uploadet", "logsUploadFailed": "Kunne ikke uploade logs", "logId": "Log-ID"
},
"subtitlingStyling": {
"stylingOptions": "Stilindstillinger", "fontSize": "Skriftstørrelse", "textColor": "Tekstfarve",
"borderSize": "Kantstørrelse", "borderColor": "Kantfarve",
"backgroundOpacity": "Baggrundsgennemsigtighed", "backgroundColor": "Baggrundsfarve", "position": "Position"
},
"mpvConfig": {
"title": "mpv.conf", "description": "Avancerede videoafspillerindstillinger",
"presets": "Forudindstillinger", "noPresets": "Ingen gemte forudindstillinger",
"saveAsPreset": "Gem som forudindstilling...", "presetName": "Forudindstillingsnavn",
"presetNameHint": "Indtast et navn for denne forudindstilling",
"loadPreset": "Indlæs", "deletePreset": "Slet",
"presetSaved": "Forudindstilling gemt", "presetLoaded": "Forudindstilling indlæst",
"presetDeleted": "Forudindstilling slettet",
"confirmDeletePreset": "Er du sikker på, at du vil slette denne forudindstilling?",
"configPlaceholder": "gpu-api=vulkan\nhwdec=auto\n# comment"
},
"dialog": { "confirmAction": "Bekræft handling" },
"discover": {
"title": "Opdag", "switchProfile": "Skift profil", "noContentAvailable": "Intet indhold tilgængeligt",
"addMediaToLibraries": "Tilføj medier til dine biblioteker", "continueWatching": "Fortsæt med at se",
"playEpisode": "S${season}E${episode}", "overview": "Oversigt", "cast": "Rollebesætning",
"extras": "Trailere og ekstra", "seasons": "Sæsoner", "studio": "Studie", "rating": "Bedømmelse",
"episodeCount": "${count} episoder", "watchedProgress": "${watched}/${total} set",
"movie": "Film", "tvShow": "TV-serie", "minutesLeft": "${minutes} min tilbage"
},
"errors": {
"searchFailed": "Søgning mislykkedes: ${error}",
"connectionTimeout": "Forbindelsestimeout ved indlæsning af ${context}",
"connectionFailed": "Kunne ikke forbinde til Plex-server",
"failedToLoad": "Kunne ikke indlæse ${context}: ${error}", "noClientAvailable": "Ingen klient tilgængelig",
"authenticationFailed": "Godkendelse mislykkedes: ${error}",
"couldNotLaunchUrl": "Kunne ikke åbne godkendelses-URL", "pleaseEnterToken": "Indtast et token",
"invalidToken": "Ugyldigt token", "failedToVerifyToken": "Kunne ikke verificere token: ${error}",
"failedToSwitchProfile": "Kunne ikke skifte til ${displayName}"
},
"libraries": {
"title": "Biblioteker", "scanLibraryFiles": "Scan biblioteksfiler", "scanLibrary": "Scan bibliotek",
"analyze": "Analysér", "analyzeLibrary": "Analysér bibliotek", "refreshMetadata": "Opdater metadata",
"emptyTrash": "Tøm papirkurv", "emptyingTrash": "Tømmer papirkurv for \"${title}\"...",
"trashEmptied": "Papirkurv tømt for \"${title}\"",
"failedToEmptyTrash": "Kunne ikke tømme papirkurv: ${error}",
"analyzing": "Analyserer \"${title}\"...", "analysisStarted": "Analyse startet for \"${title}\"",
"failedToAnalyze": "Kunne ikke analysere bibliotek: ${error}",
"noLibrariesFound": "Ingen biblioteker fundet", "thisLibraryIsEmpty": "Dette bibliotek er tomt",
"all": "Alle", "clearAll": "Ryd alle",
"scanLibraryConfirm": "Er du sikker på, at du vil scanne \"${title}\"?",
"analyzeLibraryConfirm": "Er du sikker på, at du vil analysere \"${title}\"?",
"refreshMetadataConfirm": "Er du sikker på, at du vil opdatere metadata for \"${title}\"?",
"emptyTrashConfirm": "Er du sikker på, at du vil tømme papirkurven for \"${title}\"?",
"manageLibraries": "Administrer biblioteker", "sort": "Sortér", "sortBy": "Sortér efter",
"filters": "Filtre", "confirmActionMessage": "Er du sikker på, at du vil udføre denne handling?",
"showLibrary": "Vis bibliotek", "hideLibrary": "Skjul bibliotek",
"libraryOptions": "Biblioteksindstillinger", "content": "biblioteksindhold",
"selectLibrary": "Vælg bibliotek", "filtersWithCount": "Filtre (${count})",
"noRecommendations": "Ingen anbefalinger tilgængelige",
"noCollections": "Ingen samlinger i dette bibliotek",
"noFoldersFound": "Ingen mapper fundet", "folders": "mapper",
"tabs": { "recommended": "Anbefalet", "browse": "Gennemse", "collections": "Samlinger", "playlists": "Playlister" },
"groupings": { "title": "Gruppering", "all": "Alle", "movies": "Film", "shows": "TV-serier", "seasons": "Sæsoner", "episodes": "Episoder", "folders": "Mapper" }
},
"about": {
"title": "Om", "openSourceLicenses": "Open source-licenser", "versionLabel": "Version ${version}",
"appDescription": "En smuk Plex-klient til Flutter",
"viewLicensesDescription": "Se licenser for tredjepartsbiblioteker"
},
"serverSelection": {
"allServerConnectionsFailed": "Kunne ikke forbinde til nogen servere. Tjek dit netværk og prøv igen.",
"noServersFoundForAccount": "Ingen servere fundet for ${username} (${email})",
"failedToLoadServers": "Kunne ikke indlæse servere: ${error}"
},
"hubDetail": { "title": "Titel", "releaseYear": "Udgivelsesår", "dateAdded": "Tilføjelsesdato", "rating": "Bedømmelse", "noItemsFound": "Ingen elementer fundet" },
"logs": { "clearLogs": "Ryd logs", "copyLogs": "Kopiér logs", "uploadLogs": "Upload logs", "error": "Fejl:", "stackTrace": "Staksporing:" },
"licenses": { "relatedPackages": "Relaterede pakker", "license": "Licens", "licenseNumber": "Licens ${number}", "licensesCount": "${count} licenser" },
"navigation": { "libraries": "Biblioteker", "downloads": "Downloads", "liveTv": "Live TV" },
"liveTv": {
"title": "Live TV", "channels": "Kanaler", "guide": "Guide", "noChannels": "Ingen kanaler tilgængelige",
"noDvr": "Ingen DVR konfigureret på nogen server", "tuneFailed": "Kunne ikke tune kanal",
"loading": "Indlæser kanaler...", "nowPlaying": "Afspiller nu", "noPrograms": "Ingen programdata tilgængelig",
"channelNumber": "Kn. ${number}", "live": "LIVE", "hd": "HD", "premiere": "NY",
"reloadGuide": "Genindlæs guide", "allChannels": "Alle kanaler", "now": "Nu", "today": "I dag",
"midnight": "Midnat", "overnight": "Nat", "morning": "Morgen", "daytime": "Dagtid",
"evening": "Aften", "lateNight": "Sen aften", "whatsOn": "Hvad der kører", "watchChannel": "Se kanal"
},
"collections": {
"title": "Samlinger", "collection": "Samling", "empty": "Samlingen er tom",
"unknownLibrarySection": "Kan ikke slette: Ukendt bibliotekssektion",
"deleteCollection": "Slet samling",
"deleteConfirm": "Er du sikker på, at du vil slette \"${title}\"? Denne handling kan ikke fortrydes.",
"deleted": "Samling slettet", "deleteFailed": "Kunne ikke slette samling",
"deleteFailedWithError": "Kunne ikke slette samling: ${error}",
"failedToLoadItems": "Kunne ikke indlæse samlingselementer: ${error}",
"selectCollection": "Vælg samling", "collectionName": "Samlingsnavn",
"enterCollectionName": "Indtast samlingsnavn", "addedToCollection": "Tilføjet til samling",
"errorAddingToCollection": "Kunne ikke tilføje til samling", "created": "Samling oprettet",
"removeFromCollection": "Fjern fra samling",
"removeFromCollectionConfirm": "Fjern \"${title}\" fra denne samling?",
"removedFromCollection": "Fjernet fra samling",
"removeFromCollectionFailed": "Kunne ikke fjerne fra samling",
"removeFromCollectionError": "Fejl ved fjernelse fra samling: ${error}"
},
"playlists": {
"title": "Playlister", "playlist": "Playliste", "noPlaylists": "Ingen playlister fundet",
"create": "Opret playliste", "playlistName": "Playlistenavn", "enterPlaylistName": "Indtast playlistenavn",
"delete": "Slet playliste", "removeItem": "Fjern fra playliste", "smartPlaylist": "Smart playliste",
"itemCount": "${count} elementer", "oneItem": "1 element", "emptyPlaylist": "Denne playliste er tom",
"deleteConfirm": "Slet playliste?", "deleteMessage": "Er du sikker på, at du vil slette \"${name}\"?",
"created": "Playliste oprettet", "deleted": "Playliste slettet",
"itemAdded": "Tilføjet til playliste", "itemRemoved": "Fjernet fra playliste",
"selectPlaylist": "Vælg playliste", "errorCreating": "Kunne ikke oprette playliste",
"errorDeleting": "Kunne ikke slette playliste", "errorLoading": "Kunne ikke indlæse playlister",
"errorAdding": "Kunne ikke tilføje til playliste",
"errorReordering": "Kunne ikke ændre rækkefølge på playlisteelement",
"errorRemoving": "Kunne ikke fjerne fra playliste"
},
"watchTogether": {
"title": "Se sammen", "description": "Se indhold synkroniseret med venner og familie",
"createSession": "Opret session", "creating": "Opretter...",
"joinSession": "Deltag i session", "joining": "Deltager...",
"controlMode": "Kontroltilstand", "controlModeQuestion": "Hvem kan styre afspilning?",
"hostOnly": "Kun vært", "anyone": "Alle", "hostingSession": "Vært for session",
"inSession": "I session", "sessionCode": "Sessionskode",
"hostControlsPlayback": "Vært styrer afspilning", "anyoneCanControl": "Alle kan styre afspilning",
"hostControls": "Værtskontrol", "anyoneControls": "Alle styrer",
"participants": "Deltagere", "host": "Vært", "hostBadge": "HOST",
"youAreHost": "Du er vært", "watchingWithOthers": "Ser med andre",
"endSession": "Afslut session", "leaveSession": "Forlad session",
"endSessionQuestion": "Afslut session?", "leaveSessionQuestion": "Forlad session?",
"endSessionConfirm": "Dette afslutter sessionen for alle deltagere.",
"leaveSessionConfirm": "Du vil blive fjernet fra sessionen.",
"endSessionConfirmOverlay": "Dette afslutter se-sessionen for alle deltagere.",
"leaveSessionConfirmOverlay": "Du vil blive afbrudt fra se-sessionen.",
"end": "Afslut", "leave": "Forlad", "syncing": "Synkroniserer...",
"joinWatchSession": "Deltag i se-session", "enterCodeHint": "Indtast 8-tegns kode",
"pasteFromClipboard": "Indsæt fra udklipsholder", "pleaseEnterCode": "Indtast en sessionskode",
"codeMustBe8Chars": "Sessionskode skal være 8 tegn",
"joinInstructions": "Indtast sessionskoden delt af værten for at deltage i se-sessionen.",
"failedToCreate": "Kunne ikke oprette session", "failedToJoin": "Kunne ikke deltage i session",
"sessionCodeCopied": "Sessionskode kopieret til udklipsholder",
"relayUnreachable": "Relay-serveren kan ikke nås. Dette kan skyldes, at din udbyder blokerer forbindelsen. Du kan stadig prøve, men Se sammen virker muligvis ikke.",
"reconnectingToHost": "Genopretter forbindelse til vært...",
"currentPlayback": "Nuværende afspilning", "joinCurrentPlayback": "Deltag i nuværende afspilning",
"joinCurrentPlaybackDescription": "Hop tilbage til det værten ser nu",
"failedToOpenCurrentPlayback": "Kunne ikke åbne nuværende afspilning",
"participantJoined": "${name} deltog", "participantLeft": "${name} forlod"
},
"downloads": {
"title": "Downloads", "manage": "Administrer", "tvShows": "TV-serier", "movies": "Film",
"noDownloads": "Ingen downloads endnu",
"noDownloadsDescription": "Downloadet indhold vises her til offlinevisning",
"downloadNow": "Download", "deleteDownload": "Slet download", "retryDownload": "Prøv download igen",
"downloadQueued": "Download i kø", "episodesQueued": "${count} episoder i downloadkø",
"downloadDeleted": "Download slettet",
"deleteConfirm": "Er du sikker på, at du vil slette \"${title}\"? Den downloadede fil fjernes fra din enhed.",
"deletingWithProgress": "Sletter ${title}... (${current} af ${total})",
"noDownloadsTree": "Ingen downloads", "pauseAll": "Pause alle", "resumeAll": "Genoptag alle", "deleteAll": "Slet alle"
},
"shaders": {
"title": "Shadere", "noShaderDescription": "Ingen videoforbedring",
"nvscalerDescription": "NVIDIA-billedskalering for skarpere video",
"qualityFast": "Hurtig", "qualityHQ": "Høj kvalitet", "mode": "Tilstand",
"importShader": "Importér shader", "customShaderDescription": "Brugerdefineret GLSL-shader",
"shaderImported": "Shader importeret", "shaderImportFailed": "Kunne ikke importere shader",
"deleteShader": "Slet shader", "deleteShaderConfirm": "Slet \"${name}\"?"
},
"companionRemote": {
"title": "Fjernbetjening", "connectToDevice": "Forbind til enhed",
"hostRemoteSession": "Vært for fjernsession",
"controlThisDevice": "Styr denne enhed med din telefon",
"remoteControl": "Fjernbetjening", "controlDesktop": "Styr en desktopenhed",
"connectedTo": "Forbundet til ${name}",
"session": {
"creatingSession": "Opretter fjernsession...", "failedToCreate": "Kunne ikke oprette fjernsession:",
"noSession": "Ingen session tilgængelig", "scanQrCode": "Scan QR-kode",
"orEnterManually": "Eller indtast manuelt", "hostAddress": "Værtadresse",
"sessionId": "Sessions-ID", "pin": "PIN", "connected": "Forbundet",
"waitingForConnection": "Venter på forbindelse...",
"usePhoneToControl": "Brug din mobilenhed til at styre denne app",
"copiedToClipboard": "${label} kopieret til udklipsholder",
"copyToClipboard": "Kopiér til udklipsholder", "newSession": "Ny session", "minimize": "Minimér"
},
"pairing": {
"scan": "Scan", "manual": "Manuel", "pairWithDesktop": "Par med desktop",
"enterSessionDetails": "Indtast sessionsdetaljerne vist på din desktopenhed",
"hostAddressHint": "192.168.1.100:48632", "sessionIdHint": "Indtast 8-tegns sessions-ID",
"pinHint": "Indtast 6-cifret PIN", "connecting": "Forbinder...", "tips": "Tips",
"tipDesktop": "Åbn Plezy på din desktop og aktivér fjernbetjening fra indstillinger eller menu",
"tipScan": "Brug fanen Scan til hurtigt at parre ved at scanne QR-koden på din desktop",
"tipWifi": "Sørg for, at begge enheder er på det samme WiFi-netværk",
"cameraPermissionRequired": "Kameratilladelse er påkrævet for at scanne QR-koder.\nGiv kameraadgang i enhedsindstillinger.",
"cameraError": "Kunne ikke starte kamera: ${error}",
"scanInstruction": "Ret kameraet mod QR-koden vist på din desktop",
"invalidQrCode": "Ugyldigt QR-kodeformat", "validationHostRequired": "Indtast værtadresse",
"validationHostFormat": "Format skal være IP:port (f.eks. 192.168.1.100:48632)",
"validationSessionIdRequired": "Indtast et sessions-ID",
"validationSessionIdLength": "Sessions-ID skal være 8 tegn",
"validationPinRequired": "Indtast en PIN", "validationPinLength": "PIN skal være 6 cifre",
"connectionTimedOut": "Forbindelsen fik timeout. Tjek sessions-ID og PIN.",
"sessionNotFound": "Kunne ikke finde sessionen. Tjek dine oplysninger.",
"failedToConnect": "Kunne ikke forbinde: ${error}"
},
"remote": {
"disconnectConfirm": "Vil du afbryde fra fjernsessionen?", "reconnecting": "Genopretter forbindelse...",
"attemptOf": "Forsøg ${current} af 5", "retryNow": "Prøv igen nu",
"connectionError": "Forbindelsesfejl", "notConnected": "Ikke forbundet",
"tabRemote": "Fjernbetjening", "tabPlay": "Afspil", "tabMore": "Mere", "menu": "Menu",
"tabNavigation": "Fanenavigation", "tabDiscover": "Opdag", "tabLibraries": "Biblioteker",
"tabSearch": "Søg", "tabDownloads": "Downloads", "tabSettings": "Indstillinger",
"previous": "Forrige", "playPause": "Afspil/Pause", "next": "Næste", "seekBack": "Spol tilbage",
"stop": "Stop", "seekForward": "Spol frem", "volume": "Lydstyrke", "volumeDown": "Ned",
"volumeUp": "Op", "fullscreen": "Fuldskærm", "subtitles": "Undertekster", "audio": "Lyd",
"searchHint": "Søg på desktop..."
}
},
"videoSettings": {
"playbackSettings": "Afspilningsindstillinger", "playbackSpeed": "Afspilningshastighed",
"sleepTimer": "Sove-timer", "audioSync": "Lydsynkronisering",
"subtitleSync": "Undertekstsynkronisering", "hdr": "HDR", "audioOutput": "Lydoutput",
"performanceOverlay": "Ydelsesoverlay", "audioPassthrough": "Lyd-passthrough",
"audioNormalization": "Lydnormalisering"
},
"externalPlayer": {
"title": "Ekstern afspiller", "useExternalPlayer": "Brug ekstern afspiller",
"useExternalPlayerDescription": "Åbn videoer i en ekstern app i stedet for den indbyggede afspiller",
"selectPlayer": "Vælg afspiller", "systemDefault": "Systemstandard",
"addCustomPlayer": "Tilføj brugerdefineret afspiller", "playerName": "Afspillernavn",
"playerCommand": "Kommando", "playerPackage": "Pakkenavn", "playerUrlScheme": "URL-skema",
"customPlayer": "Brugerdefineret afspiller", "off": "Fra",
"launchFailed": "Kunne ikke åbne ekstern afspiller",
"appNotInstalled": "${name} er ikke installeret", "playInExternalPlayer": "Afspil i ekstern afspiller"
},
"metadataEdit": {
"editMetadata": "Redigér...", "screenTitle": "Redigér metadata", "basicInfo": "Grundlæggende info",
"artwork": "Grafik", "advancedSettings": "Avancerede indstillinger", "title": "Titel",
"sortTitle": "Sorteringstitel", "originalTitle": "Originaltitel", "releaseDate": "Udgivelsesdato",
"contentRating": "Aldersgrænse", "studio": "Studie", "tagline": "Tagline", "summary": "Resumé",
"poster": "Plakat", "background": "Baggrund", "selectPoster": "Vælg plakat",
"selectBackground": "Vælg baggrund", "fromUrl": "Fra URL", "uploadFile": "Upload fil",
"enterImageUrl": "Indtast billed-URL", "imageUrl": "Billed-URL",
"metadataUpdated": "Metadata opdateret", "metadataUpdateFailed": "Kunne ikke opdatere metadata",
"artworkUpdated": "Grafik opdateret", "artworkUpdateFailed": "Kunne ikke opdatere grafik",
"noArtworkAvailable": "Ingen grafik tilgængelig", "notSet": "Ikke indstillet",
"libraryDefault": "Biblioteksstandard", "accountDefault": "Kontostandard",
"seriesDefault": "Seriestandard", "episodeSorting": "Episodesortering",
"oldestFirst": "Ældste først", "newestFirst": "Nyeste først", "keep": "Behold",
"allEpisodes": "Alle episoder", "latestEpisodes": "${count} seneste episoder",
"latestEpisode": "Seneste episode",
"episodesAddedPastDays": "Episoder tilføjet de seneste ${count} dage",
"deleteAfterPlaying": "Slet episoder efter afspilning", "never": "Aldrig",
"afterADay": "Efter en dag", "afterAWeek": "Efter en uge", "afterAMonth": "Efter en måned",
"onNextRefresh": "Ved næste opdatering", "seasons": "Sæsoner", "show": "Vis", "hide": "Skjul",
"episodeOrdering": "Episoderækkefølge", "tmdbAiring": "The Movie Database (Sendt)",
"tvdbAiring": "TheTVDB (Sendt)", "tvdbAbsolute": "TheTVDB (Absolut)",
"metadataLanguage": "Metadatasprog", "useOriginalTitle": "Brug originaltitel",
"preferredAudioLanguage": "Foretrukket lydsprog", "preferredSubtitleLanguage": "Foretrukket undertekstsprog",
"subtitleMode": "Auto-vælg underteksttilstand", "manuallySelected": "Manuelt valgt",
"shownWithForeignAudio": "Vist med fremmedsproget lyd", "alwaysEnabled": "Altid aktiveret"
}
}
+313 -47
View File
@@ -1,17 +1,11 @@
{
"app": {
"title": "Plezy",
"loading": "Lädt..."
"title": "Plezy"
},
"auth": {
"signInWithPlex": "Mit Plex anmelden",
"showQRCode": "QR-Code anzeigen",
"cancel": "Abbrechen",
"authenticate": "Authentifizieren",
"retry": "Erneut versuchen",
"debugEnterToken": "Debug: Plex-Token eingeben",
"plexTokenLabel": "Plex-Auth-Token",
"plexTokenHint": "Plex.tv-Token eingeben",
"authenticationTimeout": "Authentifizierung abgelaufen. Bitte erneut versuchen.",
"scanQRToSignIn": "QR-Code scannen zum Anmelden",
"waitingForAuth": "Warte auf Authentifizierung...\nBitte Anmeldung im Browser abschließen.",
@@ -34,14 +28,40 @@
"no": "Nein",
"delete": "Löschen",
"shuffle": "Zufall",
"addTo": "Hinzufügen zu..."
"addTo": "Hinzufügen zu...",
"createNew": "Neu erstellen",
"remove": "Entfernen",
"paste": "Einfügen",
"connect": "Verbinden",
"disconnect": "Trennen",
"play": "Abspielen",
"pause": "Pause",
"resume": "Fortsetzen",
"error": "Fehler",
"search": "Suche",
"home": "Start",
"back": "Zurück",
"settings": "Optionen",
"mute": "Stumm",
"ok": "OK",
"loading": "Laden...",
"reconnect": "Erneut verbinden",
"exitConfirmTitle": "App beenden?",
"exitConfirmMessage": "Möchtest du die App wirklich beenden?",
"dontAskAgain": "Nicht erneut fragen",
"exit": "Beenden",
"viewAll": "Alle anzeigen",
"checkingNetwork": "Netzwerk wird geprüft...",
"refreshingServers": "Server werden aktualisiert...",
"loadingServers": "Server werden geladen...",
"connectingToServers": "Verbindung zu Servern...",
"startingOfflineMode": "Offlinemodus wird gestartet..."
},
"screens": {
"licenses": "Lizenzen",
"switchProfile": "Profil wechseln",
"subtitleStyling": "Untertitel-Stil",
"mpvConfig": "MPV-Konfiguration",
"search": "Suche",
"mpvConfig": "mpv.conf",
"logs": "Protokolle"
},
"update": {
@@ -100,15 +120,19 @@
"alwaysKeepSidebarOpenDescription": "Seitenleiste bleibt erweitert und Inhaltsbereich passt sich an",
"showUnwatchedCount": "Anzahl nicht gesehener Folgen anzeigen",
"showUnwatchedCountDescription": "Zeigt die Anzahl nicht gesehener Episoden bei Serien und Staffeln an",
"hideSpoilers": "Spoiler für nicht gesehene Episoden verbergen",
"hideSpoilersDescription": "Vorschaubilder unscharf machen und Beschreibungen für noch nicht gesehene Episoden ausblenden",
"playerBackend": "Player-Backend",
"exoPlayer": "ExoPlayer (Empfohlen)",
"exoPlayerDescription": "Android-nativer Player mit besserer Hardware-Unterstützung",
"mpv": "MPV",
"mpv": "mpv",
"mpvDescription": "Erweiterter Player mit mehr Funktionen und ASS-Untertitel-Unterstützung",
"hardwareDecoding": "Hardware-Decodierung",
"hardwareDecodingDescription": "Hardwarebeschleunigung verwenden, sofern verfügbar",
"bufferSize": "Puffergröße",
"bufferSizeMB": "${size}MB",
"bufferSizeAuto": "Auto (Empfohlen)",
"bufferSizeWarning": "Ihr Gerät hat ${heap}MB Speicher. Ein ${size}MB-Puffer kann Wiedergabeprobleme verursachen.",
"subtitleStyling": "Untertitel-Stil",
"subtitleStylingDescription": "Aussehen von Untertiteln anpassen",
"smallSkipDuration": "Kleine Sprungdauer",
@@ -125,6 +149,8 @@
"keyboardShortcutsDescription": "Tastenkürzel anpassen",
"videoPlayerNavigation": "Videoplayer-Navigation",
"videoPlayerNavigationDescription": "Pfeiltasten zur Navigation der Videoplayer-Steuerung verwenden",
"crashReporting": "Absturzberichte",
"crashReportingDescription": "Absturzberichte senden, um die App zu verbessern",
"debugLogging": "Debug-Protokollierung",
"debugLoggingDescription": "Detaillierte Protokolle zur Fehleranalyse aktivieren",
"viewLogs": "Protokolle anzeigen",
@@ -152,6 +178,11 @@
"autoSkipCreditsDescription": "Abspann automatisch überspringen und nächste Episode abspielen",
"autoSkipDelay": "Verzögerung für automatisches Überspringen",
"autoSkipDelayDescription": "${seconds} Sekunden vor dem automatischen Überspringen warten",
"introPattern": "Intro-Markierungsmuster",
"introPatternDescription": "Regulärer Ausdruck zum Erkennen von Intro-Markierungen in Kapiteltiteln",
"creditsPattern": "Abspann-Markierungsmuster",
"creditsPatternDescription": "Regulärer Ausdruck zum Erkennen von Abspann-Markierungen in Kapiteltiteln",
"invalidRegex": "Ungültiger regulärer Ausdruck",
"downloads": "Downloads",
"downloadLocationDescription": "Speicherort für heruntergeladene Inhalte wählen",
"downloadLocationDefault": "Standard (App-Speicher)",
@@ -171,8 +202,18 @@
"maxVolumePercent": "${percent}%",
"discordRichPresence": "Discord Rich Presence",
"discordRichPresenceDescription": "Zeige auf Discord, was du gerade schaust",
"autoPip": "Automatisches Bild-in-Bild",
"autoPipDescription": "Automatisch Bild-in-Bild aktivieren, wenn die App während der Wiedergabe verlassen wird",
"matchContentFrameRate": "Inhalts-Bildrate anpassen",
"matchContentFrameRateDescription": "Bildwiederholfrequenz des Displays an den Videoinhalt anpassen, reduziert Ruckeln und spart Akku"
"matchContentFrameRateDescription": "Bildwiederholfrequenz des Displays an den Videoinhalt anpassen, reduziert Ruckeln und spart Akku",
"tunneledPlayback": "Tunnelwiedergabe",
"tunneledPlaybackDescription": "Hardware-beschleunigte Video-Tunnelierung verwenden. Deaktivieren, wenn bei HDR-Inhalten ein schwarzer Bildschirm mit Ton erscheint",
"requireProfileSelectionOnOpen": "Profil beim Öffnen abfragen",
"requireProfileSelectionOnOpenDescription": "Profilauswahl bei jedem Öffnen der App anzeigen",
"confirmExitOnBack": "Vor dem Beenden bestätigen",
"confirmExitOnBackDescription": "Bestätigungsdialog anzeigen, wenn Zurück zum Beenden der App gedrückt wird",
"showNavBarLabels": "Navigationsleisten-Beschriftungen anzeigen",
"showNavBarLabelsDescription": "Textbeschriftungen unter den Symbolen der Navigationsleiste anzeigen"
},
"search": {
"hint": "Filme, Serien, Musik suchen...",
@@ -201,7 +242,8 @@
"speedReset": "Geschwindigkeit zurücksetzen",
"subSeekNext": "Zum nächsten Untertitel springen",
"subSeekPrev": "Zum vorherigen Untertitel springen",
"shaderToggle": "Shader umschalten"
"shaderToggle": "Shader umschalten",
"skipMarker": "Intro/Abspann überspringen"
}
},
"pinEntry": {
@@ -242,10 +284,12 @@
"goToSeason": "Zur Staffel",
"shufflePlay": "Zufallswiedergabe",
"fileInfo": "Dateiinfo",
"confirmDelete": "Sind Sie sicher, dass Sie dieses Element aus Ihrem Dateisystem löschen möchten?",
"deleteMultipleWarning": "Mehrere Elemente können gelöscht werden.",
"deleteFromServer": "Vom Server löschen",
"confirmDelete": "Dieses Medium und seine Dateien werden dauerhaft von Ihrem Server gelöscht. Dies kann nicht rückgängig gemacht werden.",
"deleteMultipleWarning": "Dies umfasst alle Episoden und deren Dateien.",
"mediaDeletedSuccessfully": "Medienelement erfolgreich gelöscht",
"mediaFailedToDelete": "Löschen des Medienelements fehlgeschlagen"
"mediaFailedToDelete": "Löschen des Medienelements fehlgeschlagen",
"rate": "Bewerten"
},
"accessibility": {
"mediaCardMovie": "${title}, Film",
@@ -259,6 +303,7 @@
},
"tooltips": {
"shufflePlay": "Zufallswiedergabe",
"playTrailer": "Trailer abspielen",
"markAsWatched": "Als gesehen markieren",
"markAsUnwatched": "Als ungesehen markieren"
},
@@ -279,6 +324,9 @@
"timerActive": "Schlaftimer aktiv",
"playbackWillPauseIn": "Wiedergabe wird in ${duration} pausiert",
"sleepTimerCompleted": "Schlaftimer abgelaufen – Wiedergabe pausiert",
"stillWatching": "Schaust du noch?",
"pausingIn": "Pause in ${seconds}s",
"continueWatching": "Weiter",
"autoPlayNext": "Nächstes automatisch abspielen",
"playNext": "Nächstes abspielen",
"playButton": "Wiedergeben",
@@ -294,10 +342,14 @@
"settingsButton": "Videoeinstellungen",
"audioTrackButton": "Tonspuren",
"subtitlesButton": "Untertitel",
"tracksButton": "Audio und Untertitel",
"chaptersButton": "Kapitel",
"versionsButton": "Videoversionen",
"pipButton": "Bild-in-Bild Modus",
"aspectRatioButton": "Seitenverhältnis",
"ambientLighting": "Umgebungsbeleuchtung",
"ambientLightingOn": "Umgebungsbeleuchtung aktivieren",
"ambientLightingOff": "Umgebungsbeleuchtung deaktivieren",
"fullscreenButton": "Vollbild aktivieren",
"exitFullscreenButton": "Vollbild verlassen",
"alwaysOnTopButton": "Immer im Vordergrund",
@@ -305,15 +357,21 @@
"timelineSlider": "Video-Zeitleiste",
"volumeSlider": "Lautstärkepegel",
"endsAt": "Endet um ${time}",
"backButton": "Zurück",
"pipActive": "Wiedergabe im Bild-in-Bild-Modus",
"pipFailed": "Bild-in-Bild konnte nicht gestartet werden",
"pipErrors": {
"androidVersion": "Erfordert Android 8.0 oder neuer",
"iosVersion": "Erfordert iOS 15.0 oder neuer",
"permissionDisabled": "Bild-in-Bild-Berechtigung ist deaktiviert. Aktiviere sie unter Einstellungen > Apps > Plezy > Bild-in-Bild",
"notSupported": "Dieses Gerät unterstützt den Bild-in-Bild-Modus nicht",
"voSwitchFailed": "Videoausgabe für Bild-in-Bild konnte nicht umgeschaltet werden",
"failed": "Bild-in-Bild konnte nicht gestartet werden",
"unknown": "Ein Fehler ist aufgetreten: ${error}"
}
},
"chapters": "Kapitel",
"noChaptersAvailable": "Keine Kapitel verfügbar",
"queue": "Warteschlange",
"noQueueItems": "Keine Elemente in der Warteschlange"
},
"userStatus": {
"admin": "Eigentümer",
@@ -351,7 +409,10 @@
"noItemsAvailable": "Keine Elemente verfügbar",
"failedToCreatePlayQueueNoItems": "Wiedergabewarteschlange konnte nicht erstellt werden – keine Elemente",
"failedPlayback": "Wiedergabe für ${action} fehlgeschlagen: ${error}",
"switchingToCompatiblePlayer": "Wechsle zu kompatiblem Player..."
"switchingToCompatiblePlayer": "Wechsle zu kompatiblem Player...",
"logsUploaded": "Protokolle hochgeladen",
"logsUploadFailed": "Protokolle konnten nicht hochgeladen werden",
"logId": "Protokoll-ID"
},
"subtitlingStyling": {
"stylingOptions": "Stiloptionen",
@@ -360,22 +421,14 @@
"borderSize": "Rahmengröße",
"borderColor": "Rahmenfarbe",
"backgroundOpacity": "Hintergrunddeckkraft",
"backgroundColor": "Hintergrundfarbe"
"backgroundColor": "Hintergrundfarbe",
"position": "Position"
},
"mpvConfig": {
"title": "MPV-Konfiguration",
"title": "mpv-Konfiguration",
"description": "Erweiterte Videoplayer-Einstellungen",
"properties": "Eigenschaften",
"presets": "Voreinstellungen",
"noProperties": "Keine Eigenschaften konfiguriert",
"noPresets": "Keine gespeicherten Voreinstellungen",
"addProperty": "Eigenschaft hinzufügen",
"editProperty": "Eigenschaft bearbeiten",
"deleteProperty": "Eigenschaft löschen",
"propertyKey": "Eigenschaftsschlüssel",
"propertyKeyHint": "z.B. hwdec, demuxer-max-bytes",
"propertyValue": "Eigenschaftswert",
"propertyValueHint": "z.B. auto, 256000000",
"saveAsPreset": "Als Voreinstellung speichern...",
"presetName": "Name der Voreinstellung",
"presetNameHint": "Namen für diese Voreinstellung eingeben",
@@ -385,25 +438,21 @@
"presetLoaded": "Voreinstellung geladen",
"presetDeleted": "Voreinstellung gelöscht",
"confirmDeletePreset": "Möchten Sie diese Voreinstellung wirklich löschen?",
"confirmDeleteProperty": "Möchten Sie diese Eigenschaft wirklich löschen?",
"entriesCount": "${count} Einträge"
"configPlaceholder": "gpu-api=vulkan\nhwdec=auto\n# comment"
},
"dialog": {
"confirmAction": "Aktion bestätigen",
"cancel": "Abbrechen"
"confirmAction": "Aktion bestätigen"
},
"discover": {
"title": "Entdecken",
"switchProfile": "Profil wechseln",
"logout": "Abmelden",
"noContentAvailable": "Kein Inhalt verfügbar",
"addMediaToLibraries": "Medien zur Mediathek hinzufügen",
"continueWatching": "Weiterschauen",
"play": "Abspielen",
"playEpisode": "S${season}E${episode}",
"pause": "Pause",
"overview": "Übersicht",
"cast": "Besetzung",
"extras": "Trailer & Extras",
"seasons": "Staffeln",
"studio": "Studio",
"rating": "Altersfreigabe",
@@ -470,6 +519,7 @@
"playlists": "Wiedergabelisten"
},
"groupings": {
"title": "Gruppierung",
"all": "Alle",
"movies": "Filme",
"shows": "Serien",
@@ -500,6 +550,7 @@
"logs": {
"clearLogs": "Protokolle löschen",
"copyLogs": "Protokolle kopieren",
"uploadLogs": "Protokolle hochladen",
"error": "Fehler:",
"stackTrace": "Stacktrace:"
},
@@ -510,11 +561,36 @@
"licensesCount": "${count} Lizenzen"
},
"navigation": {
"home": "Start",
"search": "Suche",
"libraries": "Mediatheken",
"settings": "Einstellungen",
"downloads": "Downloads"
"libraries": "Medien",
"downloads": "Downloads",
"liveTv": "Live-TV"
},
"liveTv": {
"title": "Live-TV",
"channels": "Kanäle",
"guide": "Programmführer",
"noChannels": "Keine Kanäle verfügbar",
"noDvr": "Kein DVR auf einem Server konfiguriert",
"tuneFailed": "Kanal konnte nicht eingestellt werden",
"loading": "Kanäle werden geladen...",
"nowPlaying": "Läuft gerade",
"noPrograms": "Keine Programmdaten verfügbar",
"channelNumber": "Kanal ${number}",
"live": "LIVE",
"hd": "HD",
"premiere": "NEU",
"reloadGuide": "Programmführer neu laden",
"allChannels": "Alle Kanäle",
"now": "Jetzt",
"today": "Heute",
"midnight": "Mitternacht",
"overnight": "Nacht",
"morning": "Morgen",
"daytime": "Tagsüber",
"evening": "Abend",
"lateNight": "Spätnacht",
"whatsOn": "Jetzt im TV",
"watchChannel": "Kanal ansehen"
},
"downloads": {
"title": "Downloads",
@@ -530,7 +606,11 @@
"episodesQueued": "${count} Episoden zum Download hinzugefügt",
"downloadDeleted": "Download gelöscht",
"deleteConfirm": "Möchtest du \"${title}\" wirklich löschen? Die heruntergeladene Datei wird von deinem Gerät entfernt.",
"deletingWithProgress": "Lösche ${title}... (${current} von ${total})"
"deletingWithProgress": "Lösche ${title}... (${current} von ${total})",
"noDownloadsTree": "Keine Downloads",
"pauseAll": "Alle pausieren",
"resumeAll": "Alle fortsetzen",
"deleteAll": "Alle löschen"
},
"playlists": {
"title": "Wiedergabelisten",
@@ -551,7 +631,6 @@
"itemAdded": "Zur Wiedergabeliste hinzugefügt",
"itemRemoved": "Aus Wiedergabeliste entfernt",
"selectPlaylist": "Wiedergabeliste auswählen",
"createNewPlaylist": "Neue Wiedergabeliste erstellen",
"errorCreating": "Wiedergabeliste konnte nicht erstellt werden",
"errorDeleting": "Wiedergabeliste konnte nicht gelöscht werden",
"errorLoading": "Wiedergabelisten konnten nicht geladen werden",
@@ -572,7 +651,6 @@
"deleteFailedWithError": "Sammlung konnte nicht gelöscht werden: ${error}",
"failedToLoadItems": "Sammlungselemente konnten nicht geladen werden: ${error}",
"selectCollection": "Sammlung auswählen",
"createNewCollection": "Neue Sammlung erstellen",
"collectionName": "Sammlungsname",
"enterCollectionName": "Sammlungsnamen eingeben",
"addedToCollection": "Zur Sammlung hinzugefügt",
@@ -626,7 +704,15 @@
"joinInstructions": "Gib den vom Host geteilten Sitzungscode ein, um seiner Schausitzung beizutreten.",
"failedToCreate": "Sitzung konnte nicht erstellt werden",
"failedToJoin": "Sitzung konnte nicht beigetreten werden",
"sessionCodeCopied": "Sitzungscode in Zwischenablage kopiert"
"sessionCodeCopied": "Sitzungscode in Zwischenablage kopiert",
"relayUnreachable": "Der Relay-Server ist nicht erreichbar. Möglicherweise blockiert dein Internetanbieter die Verbindung. Du kannst es trotzdem versuchen, aber Watch Together funktioniert eventuell nicht.",
"reconnectingToHost": "Verbindung zum Host wird wiederhergestellt...",
"currentPlayback": "Aktuelle Wiedergabe",
"joinCurrentPlayback": "Aktuelle Wiedergabe beitreten",
"joinCurrentPlaybackDescription": "Springe zurück zu dem, was der Host gerade ansieht",
"failedToOpenCurrentPlayback": "Aktuelle Wiedergabe konnte nicht geöffnet werden",
"participantJoined": "${name} ist beigetreten",
"participantLeft": "${name} hat die Sitzung verlassen"
},
"shaders": {
"title": "Shader",
@@ -634,6 +720,186 @@
"nvscalerDescription": "NVIDIA-Bildskalierung für schärferes Video",
"qualityFast": "Schnell",
"qualityHQ": "Hohe Qualität",
"mode": "Modus"
"mode": "Modus",
"importShader": "Shader importieren",
"customShaderDescription": "Benutzerdefinierter GLSL-Shader",
"shaderImported": "Shader importiert",
"shaderImportFailed": "Shader konnte nicht importiert werden",
"deleteShader": "Shader löschen",
"deleteShaderConfirm": "\"${name}\" löschen?"
},
"companionRemote": {
"title": "Companion-Fernbedienung",
"connectToDevice": "Mit Gerät verbinden",
"hostRemoteSession": "Fernsteuerungssitzung starten",
"controlThisDevice": "Dieses Gerät mit dem Handy steuern",
"remoteControl": "Fernsteuerung",
"controlDesktop": "Ein Desktop-Gerät steuern",
"connectedTo": "Verbunden mit ${name}",
"session": {
"creatingSession": "Fernsteuerungssitzung wird erstellt...",
"failedToCreate": "Fernsteuerungssitzung konnte nicht erstellt werden:",
"noSession": "Keine Sitzung verfügbar",
"scanQrCode": "QR-Code scannen",
"orEnterManually": "Oder manuell eingeben",
"hostAddress": "Host-Adresse",
"sessionId": "Sitzungs-ID",
"pin": "PIN",
"connected": "Verbunden",
"waitingForConnection": "Warte auf Verbindung...",
"usePhoneToControl": "Verwende dein Mobilgerät, um diese App zu steuern",
"copiedToClipboard": "${label} in Zwischenablage kopiert",
"copyToClipboard": "In Zwischenablage kopieren",
"newSession": "Neue Sitzung",
"minimize": "Minimieren"
},
"pairing": {
"scan": "Scannen",
"manual": "Manuell",
"pairWithDesktop": "Mit Desktop koppeln",
"enterSessionDetails": "Gib die Sitzungsdetails ein, die auf deinem Desktop-Gerät angezeigt werden",
"hostAddressHint": "192.168.1.100:48632",
"sessionIdHint": "8-stellige Sitzungs-ID eingeben",
"pinHint": "6-stellige PIN eingeben",
"connecting": "Verbinde...",
"tips": "Tipps",
"tipDesktop": "Öffne Plezy auf deinem Desktop und aktiviere Companion Remote in den Einstellungen oder im Menü",
"tipScan": "Verwende den Scannen-Tab, um dich schnell per QR-Code auf deinem Desktop zu koppeln",
"tipWifi": "Stelle sicher, dass beide Geräte im selben WiFi-Netzwerk sind",
"cameraPermissionRequired": "Kameraberechtigung wird zum Scannen von QR-Codes benötigt.\nBitte erteile den Kamerazugriff in den Geräteeinstellungen.",
"cameraError": "Kamera konnte nicht gestartet werden: ${error}",
"scanInstruction": "Richte deine Kamera auf den QR-Code auf deinem Desktop",
"invalidQrCode": "Ungültiges QR-Code-Format",
"validationHostRequired": "Bitte Host-Adresse eingeben",
"validationHostFormat": "Format muss IP:Port sein (z.B. 192.168.1.100:48632)",
"validationSessionIdRequired": "Bitte Sitzungs-ID eingeben",
"validationSessionIdLength": "Sitzungs-ID muss 8 Zeichen lang sein",
"validationPinRequired": "Bitte PIN eingeben",
"validationPinLength": "PIN muss 6 Ziffern haben",
"connectionTimedOut": "Zeitüberschreitung. Bitte Sitzungs-ID und PIN überprüfen.",
"sessionNotFound": "Sitzung nicht gefunden. Bitte Zugangsdaten überprüfen.",
"failedToConnect": "Verbindung fehlgeschlagen: ${error}"
},
"remote": {
"disconnectConfirm": "Möchtest du die Verbindung zur Fernsteuerungssitzung trennen?",
"reconnecting": "Verbindung wird wiederhergestellt...",
"attemptOf": "Versuch ${current} von 5",
"retryNow": "Jetzt wiederholen",
"connectionError": "Verbindungsfehler",
"notConnected": "Nicht verbunden",
"tabRemote": "Fernbedienung",
"tabPlay": "Wiedergabe",
"tabMore": "Mehr",
"menu": "Menü",
"tabNavigation": "Tab-Navigation",
"tabDiscover": "Entdecken",
"tabLibraries": "Mediatheken",
"tabSearch": "Suche",
"tabDownloads": "Downloads",
"tabSettings": "Einstellungen",
"previous": "Zurück",
"playPause": "Wiedergabe/Pause",
"next": "Weiter",
"seekBack": "Zurückspulen",
"stop": "Stopp",
"seekForward": "Vorspulen",
"volume": "Lautstärke",
"volumeDown": "Leiser",
"volumeUp": "Lauter",
"fullscreen": "Vollbild",
"subtitles": "Untertitel",
"audio": "Audio",
"searchHint": "Auf Desktop suchen..."
}
},
"videoSettings": {
"playbackSettings": "Wiedergabeeinstellungen",
"playbackSpeed": "Wiedergabegeschwindigkeit",
"sleepTimer": "Schlaftimer",
"audioSync": "Audio-Synchronisation",
"subtitleSync": "Untertitel-Synchronisation",
"hdr": "HDR",
"audioOutput": "Audioausgabe",
"performanceOverlay": "Leistungsanzeige",
"audioPassthrough": "Audio-Durchleitung",
"audioNormalization": "Audio-Normalisierung"
},
"externalPlayer": {
"title": "Externer Player",
"useExternalPlayer": "Externen Player verwenden",
"useExternalPlayerDescription": "Videos in einer externen App statt im integrierten Player öffnen",
"selectPlayer": "Player auswählen",
"systemDefault": "Systemstandard",
"addCustomPlayer": "Benutzerdefinierten Player hinzufügen",
"playerName": "Playername",
"playerCommand": "Befehl",
"playerPackage": "Paketname",
"playerUrlScheme": "URL-Schema",
"customPlayer": "Benutzerdefinierter Player",
"off": "Aus",
"launchFailed": "Externer Player konnte nicht geöffnet werden",
"appNotInstalled": "${name} ist nicht installiert",
"playInExternalPlayer": "In externem Player abspielen"
},
"metadataEdit": {
"editMetadata": "Bearbeiten...",
"screenTitle": "Metadaten bearbeiten",
"basicInfo": "Grundlegende Infos",
"artwork": "Artwork",
"advancedSettings": "Erweiterte Einstellungen",
"title": "Titel",
"sortTitle": "Sortiertitel",
"originalTitle": "Originaltitel",
"releaseDate": "Erscheinungsdatum",
"contentRating": "Altersfreigabe",
"studio": "Studio",
"tagline": "Tagline",
"summary": "Zusammenfassung",
"poster": "Poster",
"background": "Hintergrund",
"selectPoster": "Poster auswählen",
"selectBackground": "Hintergrund auswählen",
"fromUrl": "Von URL",
"uploadFile": "Datei hochladen",
"enterImageUrl": "Bild-URL eingeben",
"imageUrl": "Bild-URL",
"metadataUpdated": "Metadaten aktualisiert",
"metadataUpdateFailed": "Metadaten konnten nicht aktualisiert werden",
"artworkUpdated": "Artwork aktualisiert",
"artworkUpdateFailed": "Artwork konnte nicht aktualisiert werden",
"noArtworkAvailable": "Kein Artwork verfügbar",
"notSet": "Nicht festgelegt",
"libraryDefault": "Bibliotheksstandard",
"accountDefault": "Kontostandard",
"seriesDefault": "Serienstandard",
"episodeSorting": "Episodensortierung",
"oldestFirst": "Älteste zuerst",
"newestFirst": "Neueste zuerst",
"keep": "Behalten",
"allEpisodes": "Alle Episoden",
"latestEpisodes": "${count} neueste Episoden",
"latestEpisode": "Neueste Episode",
"episodesAddedPastDays": "Episoden der letzten ${count} Tage",
"deleteAfterPlaying": "Episoden nach Wiedergabe löschen",
"never": "Nie",
"afterADay": "Nach einem Tag",
"afterAWeek": "Nach einer Woche",
"afterAMonth": "Nach einem Monat",
"onNextRefresh": "Bei nächster Aktualisierung",
"seasons": "Staffeln",
"show": "Anzeigen",
"hide": "Ausblenden",
"episodeOrdering": "Episodenreihenfolge",
"tmdbAiring": "The Movie Database (Ausgestrahlt)",
"tvdbAiring": "TheTVDB (Ausgestrahlt)",
"tvdbAbsolute": "TheTVDB (Absolut)",
"metadataLanguage": "Metadaten-Sprache",
"useOriginalTitle": "Originaltitel verwenden",
"preferredAudioLanguage": "Bevorzugte Audiosprache",
"preferredSubtitleLanguage": "Bevorzugte Untertitelsprache",
"subtitleMode": "Automatische Untertitelauswahl",
"manuallySelected": "Manuell ausgewählt",
"shownWithForeignAudio": "Bei fremdsprachigem Audio anzeigen",
"alwaysEnabled": "Immer aktiviert"
}
}
+312 -46
View File
@@ -1,17 +1,11 @@
{
"app": {
"title": "Plezy",
"loading": "Loading..."
"title": "Plezy"
},
"auth": {
"signInWithPlex": "Sign in with Plex",
"showQRCode": "Show QR Code",
"cancel": "Cancel",
"authenticate": "Authenticate",
"retry": "Retry",
"debugEnterToken": "Debug: Enter Plex Token",
"plexTokenLabel": "Plex Auth Token",
"plexTokenHint": "Enter your Plex.tv token",
"authenticationTimeout": "Authentication timed out. Please try again.",
"scanQRToSignIn": "Scan this QR code to sign in",
"waitingForAuth": "Waiting for authentication...\nPlease complete sign-in in your browser.",
@@ -34,14 +28,40 @@
"no": "No",
"delete": "Delete",
"shuffle": "Shuffle",
"addTo": "Add to..."
"addTo": "Add to...",
"createNew": "Create new",
"remove": "Remove",
"paste": "Paste",
"connect": "Connect",
"disconnect": "Disconnect",
"play": "Play",
"pause": "Pause",
"resume": "Resume",
"error": "Error",
"search": "Search",
"home": "Home",
"back": "Back",
"settings": "Settings",
"mute": "Mute",
"ok": "OK",
"loading": "Loading...",
"reconnect": "Reconnect",
"exitConfirmTitle": "Exit app?",
"exitConfirmMessage": "Are you sure you want to exit?",
"dontAskAgain": "Don't ask again",
"exit": "Exit",
"viewAll": "View All",
"checkingNetwork": "Checking network...",
"refreshingServers": "Refreshing servers...",
"loadingServers": "Loading servers...",
"connectingToServers": "Connecting to servers...",
"startingOfflineMode": "Starting offline mode..."
},
"screens": {
"licenses": "Licenses",
"switchProfile": "Switch Profile",
"subtitleStyling": "Subtitle Styling",
"mpvConfig": "MPV Configuration",
"search": "Search",
"mpvConfig": "mpv.conf",
"logs": "Logs"
},
"update": {
@@ -100,15 +120,19 @@
"alwaysKeepSidebarOpenDescription": "Sidebar stays expanded and content area adjusts to fit",
"showUnwatchedCount": "Show Unwatched Count",
"showUnwatchedCountDescription": "Display unwatched episode count on shows and seasons",
"hideSpoilers": "Hide Spoilers for Unwatched Episodes",
"hideSpoilersDescription": "Blur thumbnails and hide descriptions for episodes you haven't watched yet",
"playerBackend": "Player Backend",
"exoPlayer": "ExoPlayer (Recommended)",
"exoPlayerDescription": "Android native player with better hardware support",
"mpv": "MPV",
"mpv": "mpv",
"mpvDescription": "Advanced player with more features and ASS subtitle support",
"hardwareDecoding": "Hardware Decoding",
"hardwareDecodingDescription": "Use hardware acceleration when available",
"bufferSize": "Buffer Size",
"bufferSizeMB": "${size}MB",
"bufferSizeAuto": "Auto (Recommended)",
"bufferSizeWarning": "Your device has ${heap}MB of memory. A ${size}MB buffer may cause playback issues.",
"subtitleStyling": "Subtitle Styling",
"subtitleStylingDescription": "Customize subtitle appearance",
"smallSkipDuration": "Small Skip Duration",
@@ -125,6 +149,8 @@
"keyboardShortcutsDescription": "Customize keyboard shortcuts",
"videoPlayerNavigation": "Video Player Navigation",
"videoPlayerNavigationDescription": "Use arrow keys to navigate video player controls",
"crashReporting": "Crash Reporting",
"crashReportingDescription": "Send crash reports to help improve the app",
"debugLogging": "Debug Logging",
"debugLoggingDescription": "Enable detailed logging for troubleshooting",
"viewLogs": "View Logs",
@@ -152,6 +178,11 @@
"autoSkipCreditsDescription": "Automatically skip credits and play next episode",
"autoSkipDelay": "Auto Skip Delay",
"autoSkipDelayDescription": "Wait ${seconds} seconds before auto-skipping",
"introPattern": "Intro Marker Pattern",
"introPatternDescription": "Regex pattern to match intro markers in chapter titles",
"creditsPattern": "Credits Marker Pattern",
"creditsPatternDescription": "Regex pattern to match credits markers in chapter titles",
"invalidRegex": "Invalid regular expression",
"downloads": "Downloads",
"downloadLocationDescription": "Choose where to store downloaded content",
"downloadLocationDefault": "Default (App Storage)",
@@ -171,8 +202,18 @@
"maxVolumePercent": "${percent}%",
"discordRichPresence": "Discord Rich Presence",
"discordRichPresenceDescription": "Show what you're watching on Discord",
"autoPip": "Auto Picture-in-Picture",
"autoPipDescription": "Automatically enter picture-in-picture when leaving the app during playback",
"matchContentFrameRate": "Match Content Frame Rate",
"matchContentFrameRateDescription": "Adjust display refresh rate to match video content, reducing judder and saving battery"
"matchContentFrameRateDescription": "Adjust display refresh rate to match video content, reducing judder and saving battery",
"tunneledPlayback": "Tunneled Playback",
"tunneledPlaybackDescription": "Use hardware-accelerated video tunneling. Disable if you see a black screen with audio on HDR content",
"requireProfileSelectionOnOpen": "Ask for profile on app open",
"requireProfileSelectionOnOpenDescription": "Show profile selection every time the app is opened",
"confirmExitOnBack": "Confirm before exiting",
"confirmExitOnBackDescription": "Show a confirmation dialog when pressing back to exit the app",
"showNavBarLabels": "Show Navigation Bar Labels",
"showNavBarLabelsDescription": "Display text labels under navigation bar icons"
},
"search": {
"hint": "Search movies, shows, music...",
@@ -201,7 +242,8 @@
"speedReset": "Reset Speed",
"subSeekNext": "Seek to Next Subtitle",
"subSeekPrev": "Seek to Previous Subtitle",
"shaderToggle": "Toggle Shaders"
"shaderToggle": "Toggle Shaders",
"skipMarker": "Skip Intro/Credits"
}
},
"pinEntry": {
@@ -242,10 +284,12 @@
"goToSeason": "Go to season",
"shufflePlay": "Shuffle Play",
"fileInfo": "File Info",
"confirmDelete": "Are you sure you want to delete this item from your filesystem?",
"deleteMultipleWarning": "Multiple items may be deleted.",
"deleteFromServer": "Delete from server",
"confirmDelete": "This will permanently delete this media and its files from your server. This cannot be undone.",
"deleteMultipleWarning": "This includes all episodes and their files.",
"mediaDeletedSuccessfully": "Media item deleted successfully",
"mediaFailedToDelete": "Failed to delete media item"
"mediaFailedToDelete": "Failed to delete media item",
"rate": "Rate"
},
"accessibility": {
"mediaCardMovie": "${title}, movie",
@@ -259,6 +303,7 @@
},
"tooltips": {
"shufflePlay": "Shuffle play",
"playTrailer": "Play trailer",
"markAsWatched": "Mark as watched",
"markAsUnwatched": "Mark as unwatched"
},
@@ -279,6 +324,9 @@
"timerActive": "Timer Active",
"playbackWillPauseIn": "Playback will pause in ${duration}",
"sleepTimerCompleted": "Sleep timer completed - playback paused",
"stillWatching": "Still watching?",
"pausingIn": "Pausing in ${seconds}s",
"continueWatching": "Continue",
"autoPlayNext": "Auto-Play Next",
"playNext": "Play Next",
"playButton": "Play",
@@ -294,10 +342,14 @@
"settingsButton": "Video settings",
"audioTrackButton": "Audio tracks",
"subtitlesButton": "Subtitles",
"tracksButton": "Audio & Subtitles",
"chaptersButton": "Chapters",
"versionsButton": "Video versions",
"pipButton": "Picture-in-Picture mode",
"aspectRatioButton": "Aspect ratio",
"ambientLighting": "Ambient lighting",
"ambientLightingOn": "Enable ambient lighting",
"ambientLightingOff": "Disable ambient lighting",
"fullscreenButton": "Enter fullscreen",
"exitFullscreenButton": "Exit fullscreen",
"alwaysOnTopButton": "Always on top",
@@ -305,15 +357,21 @@
"timelineSlider": "Video timeline",
"volumeSlider": "Volume level",
"endsAt": "Ends at ${time}",
"backButton": "Back",
"pipActive": "Playing in Picture-in-Picture",
"pipFailed": "Picture-in-picture failed to start",
"pipErrors": {
"androidVersion": "Requires Android 8.0 or newer",
"iosVersion": "Requires iOS 15.0 or newer",
"permissionDisabled": "Picture-in-picture permission is disabled. Enable it in Settings > Apps > Plezy > Picture-in-picture",
"notSupported": "Device doesn't support picture-in-picture mode",
"voSwitchFailed": "Failed to switch video output for picture-in-picture",
"failed": "Picture-in-picture failed to start",
"unknown": "An error occurred: ${error}"
}
},
"chapters": "Chapters",
"noChaptersAvailable": "No chapters available",
"queue": "Queue",
"noQueueItems": "No items in queue"
},
"userStatus": {
"admin": "Admin",
@@ -351,7 +409,10 @@
"noItemsAvailable": "No items available",
"failedToCreatePlayQueueNoItems": "Failed to create play queue - no items",
"failedPlayback": "Failed to ${action}: ${error}",
"switchingToCompatiblePlayer": "Switching to compatible player..."
"switchingToCompatiblePlayer": "Switching to compatible player...",
"logsUploaded": "Logs uploaded",
"logsUploadFailed": "Failed to upload logs",
"logId": "Log ID"
},
"subtitlingStyling": {
"stylingOptions": "Styling Options",
@@ -360,22 +421,14 @@
"borderSize": "Border Size",
"borderColor": "Border Color",
"backgroundOpacity": "Background Opacity",
"backgroundColor": "Background Color"
"backgroundColor": "Background Color",
"position": "Position"
},
"mpvConfig": {
"title": "MPV Configuration",
"title": "mpv.conf",
"description": "Advanced video player settings",
"properties": "Properties",
"presets": "Presets",
"noProperties": "No properties configured",
"noPresets": "No saved presets",
"addProperty": "Add Property",
"editProperty": "Edit Property",
"deleteProperty": "Delete Property",
"propertyKey": "Property Key",
"propertyKeyHint": "e.g., hwdec, demuxer-max-bytes",
"propertyValue": "Property Value",
"propertyValueHint": "e.g., auto, 256000000",
"saveAsPreset": "Save as Preset...",
"presetName": "Preset Name",
"presetNameHint": "Enter a name for this preset",
@@ -385,25 +438,21 @@
"presetLoaded": "Preset loaded",
"presetDeleted": "Preset deleted",
"confirmDeletePreset": "Are you sure you want to delete this preset?",
"confirmDeleteProperty": "Are you sure you want to delete this property?",
"entriesCount": "${count} entries"
"configPlaceholder": "gpu-api=vulkan\nhwdec=auto\n# comment"
},
"dialog": {
"confirmAction": "Confirm Action",
"cancel": "Cancel"
"confirmAction": "Confirm Action"
},
"discover": {
"title": "Discover",
"switchProfile": "Switch Profile",
"logout": "Logout",
"noContentAvailable": "No content available",
"addMediaToLibraries": "Add some media to your libraries",
"continueWatching": "Continue Watching",
"play": "Play",
"playEpisode": "S${season}E${episode}",
"pause": "Pause",
"overview": "Overview",
"cast": "Cast",
"extras": "Trailers & Extras",
"seasons": "Seasons",
"studio": "Studio",
"rating": "Rating",
@@ -470,6 +519,7 @@
"playlists": "Playlists"
},
"groupings": {
"title": "Grouping",
"all": "All",
"movies": "Movies",
"shows": "TV Shows",
@@ -500,6 +550,7 @@
"logs": {
"clearLogs": "Clear Logs",
"copyLogs": "Copy Logs",
"uploadLogs": "Upload Logs",
"error": "Error:",
"stackTrace": "Stack Trace:"
},
@@ -510,11 +561,36 @@
"licensesCount": "${count} licenses"
},
"navigation": {
"home": "Home",
"search": "Search",
"libraries": "Libraries",
"settings": "Settings",
"downloads": "Downloads"
"downloads": "Downloads",
"liveTv": "Live TV"
},
"liveTv": {
"title": "Live TV",
"channels": "Channels",
"guide": "Guide",
"noChannels": "No channels available",
"noDvr": "No DVR configured on any server",
"tuneFailed": "Failed to tune channel",
"loading": "Loading channels...",
"nowPlaying": "Now Playing",
"noPrograms": "No program data available",
"channelNumber": "Ch. ${number}",
"live": "LIVE",
"hd": "HD",
"premiere": "NEW",
"reloadGuide": "Reload Guide",
"allChannels": "All Channels",
"now": "Now",
"today": "Today",
"midnight": "Midnight",
"overnight": "Overnight",
"morning": "Morning",
"daytime": "Daytime",
"evening": "Evening",
"lateNight": "Late Night",
"whatsOn": "What's On",
"watchChannel": "Watch Channel"
},
"collections": {
"title": "Collections",
@@ -528,7 +604,6 @@
"deleteFailedWithError": "Failed to delete collection: ${error}",
"failedToLoadItems": "Failed to load collection items: ${error}",
"selectCollection": "Select Collection",
"createNewCollection": "Create New Collection",
"collectionName": "Collection Name",
"enterCollectionName": "Enter collection name",
"addedToCollection": "Added to collection",
@@ -560,7 +635,6 @@
"itemAdded": "Added to playlist",
"itemRemoved": "Removed from playlist",
"selectPlaylist": "Select Playlist",
"createNewPlaylist": "Create New Playlist",
"errorCreating": "Failed to create playlist",
"errorDeleting": "Failed to delete playlist",
"errorLoading": "Failed to load playlists",
@@ -610,7 +684,15 @@
"joinInstructions": "Enter the session code shared by the host to join their watch session.",
"failedToCreate": "Failed to create session",
"failedToJoin": "Failed to join session",
"sessionCodeCopied": "Session code copied to clipboard"
"sessionCodeCopied": "Session code copied to clipboard",
"relayUnreachable": "The relay server is unreachable. This may be caused by your ISP blocking the connection. You can still try, but Watch Together may not work.",
"reconnectingToHost": "Reconnecting to host...",
"currentPlayback": "Current Playback",
"joinCurrentPlayback": "Join Current Playback",
"joinCurrentPlaybackDescription": "Jump back into what the host is currently watching",
"failedToOpenCurrentPlayback": "Failed to open current playback",
"participantJoined": "${name} joined",
"participantLeft": "${name} left"
},
"downloads": {
"title": "Downloads",
@@ -626,7 +708,11 @@
"episodesQueued": "${count} episodes queued for download",
"downloadDeleted": "Download deleted",
"deleteConfirm": "Are you sure you want to delete \"${title}\"? This will remove the downloaded file from your device.",
"deletingWithProgress": "Deleting ${title}... (${current} of ${total})"
"deletingWithProgress": "Deleting ${title}... (${current} of ${total})",
"noDownloadsTree": "No downloads",
"pauseAll": "Pause all",
"resumeAll": "Resume all",
"deleteAll": "Delete all"
},
"shaders": {
"title": "Shaders",
@@ -634,6 +720,186 @@
"nvscalerDescription": "NVIDIA image scaling for sharper video",
"qualityFast": "Fast",
"qualityHQ": "High Quality",
"mode": "Mode"
"mode": "Mode",
"importShader": "Import Shader",
"customShaderDescription": "Custom GLSL shader",
"shaderImported": "Shader imported",
"shaderImportFailed": "Failed to import shader",
"deleteShader": "Delete Shader",
"deleteShaderConfirm": "Delete \"${name}\"?"
},
"companionRemote": {
"title": "Companion Remote",
"connectToDevice": "Connect to Device",
"hostRemoteSession": "Host Remote Session",
"controlThisDevice": "Control this device with your phone",
"remoteControl": "Remote Control",
"controlDesktop": "Control a desktop device",
"connectedTo": "Connected to ${name}",
"session": {
"creatingSession": "Creating remote session...",
"failedToCreate": "Failed to create remote session:",
"noSession": "No session available",
"scanQrCode": "Scan QR Code",
"orEnterManually": "Or enter manually",
"hostAddress": "Host Address",
"sessionId": "Session ID",
"pin": "PIN",
"connected": "Connected",
"waitingForConnection": "Waiting for connection...",
"usePhoneToControl": "Use your mobile device to control this app",
"copiedToClipboard": "${label} copied to clipboard",
"copyToClipboard": "Copy to clipboard",
"newSession": "New Session",
"minimize": "Minimize"
},
"pairing": {
"scan": "Scan",
"manual": "Manual",
"pairWithDesktop": "Pair with Desktop",
"enterSessionDetails": "Enter the session details shown on your desktop device",
"hostAddressHint": "192.168.1.100:48632",
"sessionIdHint": "Enter 8-character session ID",
"pinHint": "Enter 6-digit PIN",
"connecting": "Connecting...",
"tips": "Tips",
"tipDesktop": "Open Plezy on your desktop and enable Companion Remote from settings or menu",
"tipScan": "Use the Scan tab to quickly pair by scanning the QR code on your desktop",
"tipWifi": "Make sure both devices are on the same WiFi network",
"cameraPermissionRequired": "Camera permission is required to scan QR codes.\nPlease grant camera access in your device settings.",
"cameraError": "Could not start camera: ${error}",
"scanInstruction": "Point your camera at the QR code shown on your desktop",
"invalidQrCode": "Invalid QR code format",
"validationHostRequired": "Please enter host address",
"validationHostFormat": "Format must be IP:port (e.g., 192.168.1.100:48632)",
"validationSessionIdRequired": "Please enter a session ID",
"validationSessionIdLength": "Session ID must be 8 characters",
"validationPinRequired": "Please enter a PIN",
"validationPinLength": "PIN must be 6 digits",
"connectionTimedOut": "Connection timed out. Please check the session ID and PIN.",
"sessionNotFound": "Could not find the session. Please check your credentials.",
"failedToConnect": "Failed to connect: ${error}"
},
"remote": {
"disconnectConfirm": "Do you want to disconnect from the remote session?",
"reconnecting": "Reconnecting...",
"attemptOf": "Attempt ${current} of 5",
"retryNow": "Retry Now",
"connectionError": "Connection error",
"notConnected": "Not connected",
"tabRemote": "Remote",
"tabPlay": "Play",
"tabMore": "More",
"menu": "Menu",
"tabNavigation": "Tab Navigation",
"tabDiscover": "Discover",
"tabLibraries": "Libraries",
"tabSearch": "Search",
"tabDownloads": "Downloads",
"tabSettings": "Settings",
"previous": "Previous",
"playPause": "Play/Pause",
"next": "Next",
"seekBack": "Seek Back",
"stop": "Stop",
"seekForward": "Seek Fwd",
"volume": "Volume",
"volumeDown": "Down",
"volumeUp": "Up",
"fullscreen": "Fullscreen",
"subtitles": "Subtitles",
"audio": "Audio",
"searchHint": "Search on desktop..."
}
},
"videoSettings": {
"playbackSettings": "Playback Settings",
"playbackSpeed": "Playback Speed",
"sleepTimer": "Sleep Timer",
"audioSync": "Audio Sync",
"subtitleSync": "Subtitle Sync",
"hdr": "HDR",
"audioOutput": "Audio Output",
"performanceOverlay": "Performance Overlay",
"audioPassthrough": "Audio Passthrough",
"audioNormalization": "Audio Normalization"
},
"externalPlayer": {
"title": "External Player",
"useExternalPlayer": "Use External Player",
"useExternalPlayerDescription": "Open videos in an external app instead of the built-in player",
"selectPlayer": "Select Player",
"systemDefault": "System Default",
"addCustomPlayer": "Add Custom Player",
"playerName": "Player Name",
"playerCommand": "Command",
"playerPackage": "Package Name",
"playerUrlScheme": "URL Scheme",
"customPlayer": "Custom Player",
"off": "Off",
"launchFailed": "Failed to open external player",
"appNotInstalled": "${name} is not installed",
"playInExternalPlayer": "Play in External Player"
},
"metadataEdit": {
"editMetadata": "Edit...",
"screenTitle": "Edit Metadata",
"basicInfo": "Basic Info",
"artwork": "Artwork",
"advancedSettings": "Advanced Settings",
"title": "Title",
"sortTitle": "Sort Title",
"originalTitle": "Original Title",
"releaseDate": "Release Date",
"contentRating": "Content Rating",
"studio": "Studio",
"tagline": "Tagline",
"summary": "Summary",
"poster": "Poster",
"background": "Background",
"selectPoster": "Select Poster",
"selectBackground": "Select Background",
"fromUrl": "From URL",
"uploadFile": "Upload File",
"enterImageUrl": "Enter image URL",
"imageUrl": "Image URL",
"metadataUpdated": "Metadata updated",
"metadataUpdateFailed": "Failed to update metadata",
"artworkUpdated": "Artwork updated",
"artworkUpdateFailed": "Failed to update artwork",
"noArtworkAvailable": "No artwork available",
"notSet": "Not set",
"libraryDefault": "Library default",
"accountDefault": "Account default",
"seriesDefault": "Series default",
"episodeSorting": "Episode Sorting",
"oldestFirst": "Oldest first",
"newestFirst": "Newest first",
"keep": "Keep",
"allEpisodes": "All episodes",
"latestEpisodes": "${count} latest episodes",
"latestEpisode": "Latest episode",
"episodesAddedPastDays": "Episodes added in the past ${count} days",
"deleteAfterPlaying": "Delete Episodes After Playing",
"never": "Never",
"afterADay": "After a day",
"afterAWeek": "After a week",
"afterAMonth": "After a month",
"onNextRefresh": "On next refresh",
"seasons": "Seasons",
"show": "Show",
"hide": "Hide",
"episodeOrdering": "Episode Ordering",
"tmdbAiring": "The Movie Database (Aired)",
"tvdbAiring": "TheTVDB (Aired)",
"tvdbAbsolute": "TheTVDB (Absolute)",
"metadataLanguage": "Metadata Language",
"useOriginalTitle": "Use Original Title",
"preferredAudioLanguage": "Preferred Audio Language",
"preferredSubtitleLanguage": "Preferred Subtitle Language",
"subtitleMode": "Auto-Select Subtitle Mode",
"manuallySelected": "Manually selected",
"shownWithForeignAudio": "Shown with foreign audio",
"alwaysEnabled": "Always enabled"
}
}

Some files were not shown because too many files have changed in this diff Show More