devtools
9857b657 - Notify Flutter inspector when navigating widget tree with keyboard (#9810)

Commit
63 days ago
Notify Flutter inspector when navigating widget tree with keyboard (#9810) * Notify Flutter inspector when navigating widget tree with keyboard * Add inspector tree left/right keyboard navigation coverage Updates inspector tree tests to cover left and right arrow navigation, including expand, next-row selection, and parent selection behavior. Also ensures left navigation to a parent notifies Flutter Inspector consistently with other keyboard selection changes. * Fix inspector widget tree visibility issues during keyboard navigation Resolves two regressions surfaced when navigating the inspector widget tree with the arrow-left key. 1. Clicking a still-visible row used to call `expandPath` on the clicked node, which re-expanded the clicked node itself and undid any subtree collapses the user had just performed via the arrow-left key. Removed the call from `onSelectNode`; programmatic selection flows (search, on-device pick) continue to call `expandPath` via `syncTreeSelection`, so external selection still works correctly. 2. Collapsing all the way to the root via the arrow-left key shrank the visible rows down to a single row, which the inspector treated as a "still loading" state and replaced with a spinner — hiding the user's `[root]` row. Gated that branch on `!firstInspectorTreeLoadCompleted` so the spinner only shows during the initial load; afterwards a one-row tree renders as the legitimate single-row state. Adds regression tests covering both behaviors. * docs: add release notes for inspector keyboard navigation fixes (#9810) * test: update inspector tree selection test for collapsed nodes
Author
Parents
Loading