Repository navigation
Let users pick their own video player instead of a hardcoded list - #488
Merged
LivingWithHippos merged 2 commits intoAug 19, 2026
Merged
LivingWithHippos merged 2 commits into
LivingWithHippos merged 2 commits into
Conversation
Replaces the hardcoded, always-stale list of known player packages with the system's own "open with" chooser: the settings row hands a small bundled placeholder clip to it so a player can be picked without needing a real video, and any installed or future player shows up with no maintenance needed (declared through a manifest <queries> entry instead of naming packages). The choice is remembered as this app's own preference via VideoPlayerChosenReceiver, since Android's OS level "always" mechanism cannot be reliably undone by a third party app on every device. Sending a remembered link straight to VLC through a plain ACTION_VIEW turned out to race against some TVs' window transition system and silently fail to show video. VLC's own source shows a plain text ACTION_SEND (what the Share button already sends) takes a different, lazier code path that avoids the race, so the preferred-player intent now special-cases VLC to use that shape. The same helper backs both "send to player" and a new "open with" entry point, which replaces the system chooser with a small in-app picker (a scrollable row of installed apps rather than Intent.createChooser) so VLC can still be routed through the safe shape once picked, and so every row is its own reachable d-pad stop.
Owner
|
nice one, I feel like we could just remove the old button and let the user pick everytime through this, but I'll merge it for now |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Replaces the hardcoded list of known player packages, which needed constant upkeep and was always missing something, with the system's own open with chooser. The settings row hands it a small bundled clip so a player can be picked without needing a real video file, and any installed or future player shows up automatically since it is declared through a manifest queries entry instead of naming packages. The choice is remembered as this app's own preference, since Android's own always mechanism for a default app cannot be reliably undone by a third party app on every device.
While testing this on a TV, sending a remembered link straight to VLC through a plain ACTION_VIEW turned out to race against the TV's window transition system and silently fail to show video. Looking at VLC's own source, a plain text ACTION_SEND (the same thing the Share button already sends it) takes a different, lazier code path that avoids the race, so the preferred player intent now special cases VLC to use that shape.
Also replaces the open with entry point with a small in app picker instead of the system chooser, so VLC can be routed through the same safe shape once picked there too, and so each app in the list is its own reachable d-pad stop.
Verified on a real Google TV Streamer, including actual playback with VLC. More testing with other players is welcome.