Fix regression where CharInput defaults to focused

Originally the File menu was getting the default focus, though this was
not useful because the menus are not keyboard accessible yet, but when I
made the menu items not accept focus, the auto focus behavior became to
focus the CharInput, causing `pytest -k test_paint_app` to fail.
No focus makes more sense than the File menu item or the CharInput.
This commit is contained in:
Isaiah Odhner 2024-11-08 11:16:18 -05:00
parent fa4d961fb4
commit 4b390d884b

View File

@ -112,6 +112,8 @@ class PaintApp(App[None]):
CSS_PATH = "paint.css" CSS_PATH = "paint.css"
AUTO_FOCUS = None
# These call action_* methods on the widget. # These call action_* methods on the widget.
# They can have parameters, if need be. # They can have parameters, if need be.
# https://textual.textualize.io/guide/actions/ # https://textual.textualize.io/guide/actions/