gpui: Fix panic with invalid focus IDs (#57885)

We were missing a check when setting the focused node ID, causing a
panic in accesskit's internal validation logic. Fixes the bug, and adds
some defensive logic to help mitigate potential future issues.

You can reproduce the panic by:
- turning on a screenreader
- launching zed
- opening a menu and pressing tab

This change fixes it.

Release Notes:

- N/A or Added/Fixed/Improved ...
777e16dd1fCameron Mcloughlin committed on 5/28/2026, 12:02:37 AM· committed by GitHubparentf0341c9
2 files changedLine totals unavailable