Skip to content

Android TV Support for Ensemble Framework #2160

@TheNoumanDev

Description

@TheNoumanDev

Summary

Ensemble's touch-first interaction model makes the app non-functional on Android TV. The framework needs D-pad focus navigation, key event handling, and TV-aware UI adjustments.

Blockers (App Non-Functional)

  • TV remote select/center button dead — no Shortcuts mapping LogicalKeyboardKey.selectActivateIntent
  • No autofocus on any widget — screens load with no focus, D-pad has no starting point
  • Zero key event handling — no KeyboardListener, onKeyEvent, or LogicalKeyboardKey usage
  • No focus-based scrolling — ListView/GridView won't scroll to keep focused item visible
  • GestureDetector-wrapped widgets unreachable — touch-only, cannot receive focus

Major Gaps (Broken Interactions)

  • Carousel — touch swipe only, no D-pad left/right support
  • Dropdown/TabBar — overlays and tabs not D-pad navigable
  • No TV device detection — no isTV() method, cannot adapt UI conditionally
  • No per-screen back button control — no PopScope usage
  • Missing TV banner icon — no android:banner or 320x180 drawable

Experience Gaps (Unpolished)

  • Focus visuals not configurable from YAML — only hardcoded blue border
  • No focus order control for YAML authors
  • No overscan safe area padding (48dp/27dp)
  • No key repeat throttling on D-pad long-press
  • No directional traversal policy for grid layouts
  • No TV-specific text scaling (10-foot UI needs 18-32sp min)

Acceptance Criteria

  1. TV remote select button activates focused widgets
  2. First focusable widget per screen receives autofocus
  3. D-pad navigates all interactive widgets; scrollable lists follow focus
  4. Carousel navigable with D-pad; back button exits properly
  5. Visible focus indicators on all interactive elements
  6. 60fps on mid-range TV hardware (MiBox, Fire TV Stick)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions