Skip to content

Add aggressive activity fallback for apps missing Leanback intent#34

Open
evanofficial wants to merge 1 commit intoTrooped:mainfrom
evanofficial:fix/leanback-intent-fallback
Open

Add aggressive activity fallback for apps missing Leanback intent#34
evanofficial wants to merge 1 commit intoTrooped:mainfrom
evanofficial:fix/leanback-intent-fallback

Conversation

@evanofficial
Copy link
Copy Markdown

Summary

  • Adds a new fallback step (step 4) in getBestLaunchIntent() that queries PackageManager.GET_ACTIVITIES to scan all declared activities when standard intent resolution fails
  • Prioritizes exported activities with entry-point keywords (main, splash, tv, leanback, launcher, home) before falling back to the first available activity
  • Handles API level differences for getPackageInfo (Tiramisu+ vs legacy)
  • Existing resolution steps (1-3) and the Amazon Prime Video special case (now step 5) are completely untouched

Testing notes

I don't have an Android TV device to verify the fix end-to-end with a problematic app like OdidoTv. Would appreciate if someone with access to a device and a known-failing app could validate.

Fixes #31

Some third-party apps (e.g. telecom/provider apps) omit the standard
CATEGORY_LEANBACK_LAUNCHER intent, causing QuickBars to fail with
"no launchable activity". This adds a new fallback step that queries
PackageManager for all declared activities and picks the best entry
point by scanning for common names like main, splash, tv, or launcher.

Fixes Trooped#31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] Launch failure for apps missing Leanback intent (no launchable activity)

1 participant