The Launcher is the central hub of the application, allowing users to quickly switch between different games and technical examples.
The LauncherState maintains a list of LauncherItem objects, each representing a state that can be pushed onto the StateManager stack.
- Search: A real-time filter allows users to find specific items by typing.
- Navigation: Supports both keyboard (Arrow keys, Enter) and mouse (clicks, scrolling) navigation.
- Scrolling: A virtualized list that only renders visible items, supporting any number of entries.
To add a new game or example:
- Create a new state implementing the
Statetrait insrc/game/orsrc/examples/. - Register the module in
src/game/mod.rsorsrc/examples/mod.rs. - Add a new
LauncherItemto theLauncherState::new()list. - Update the
matchblock inhandle_inputandhandle_mouse_clickto instantiate the new state.