bevy/examples/mobile
charlotte 3360b45153
Expose winit's MonitorHandle (#13669)
# Objective

Adds a new `Monitor` component representing a winit `MonitorHandle` that
can be used to spawn new windows and check for system monitor
information.

Closes #12955.

## Solution

For every winit event, check available monitors and spawn them into the
world as components.

## Testing

TODO:
- [x] Test plugging in and unplugging monitor during app runtime
- [x] Test spawning a window on a second monitor by entity id
- [ ] Since this touches winit, test all platforms

---

## Changelog

- Adds a new `Monitor` component that can be queried for information
about available system monitors.

## Migration Guide

- `WindowMode` variants now take a `MonitorSelection`, which can be set
to `MonitorSelection::Primary` to mirror the old behavior.

---------

Co-authored-by: Pascal Hertleif <pascal@technocreatives.com>
Co-authored-by: Alice Cecile <alice.i.cecile@gmail.com>
Co-authored-by: Pascal Hertleif <killercup@gmail.com>
2024-08-06 10:54:37 +00:00
..
bevy_mobile_example.xcodeproj daily job running mobile example on real devices (#8216) 2023-03-28 23:16:07 +00:00
ios-src IOS, Android... same thing (#7493) 2023-02-06 18:08:49 +00:00
src Expose winit's MonitorHandle (#13669) 2024-08-06 10:54:37 +00:00
.gitignore IOS, Android... same thing (#7493) 2023-02-06 18:08:49 +00:00
build_rust_deps.sh Fix alignment on ios simulator (#10178) 2023-10-21 22:19:46 +00:00
Cargo.toml Generate links to definition in source code pages on docs.rs and dev-docs.bevyengine.org (#12965) 2024-07-29 23:10:16 +00:00
Makefile Improve selection of iOS device in mobile example (#9282) 2023-10-08 20:57:41 +00:00