bevy/crates/bevy_winit/src
targrub 964b047466 Make raw_window_handle field in Window and ExtractedWindow an Option. (#6114)
# Objective

- Trying to make it possible to do write tests that don't require a raw window handle.
- Fixes https://github.com/bevyengine/bevy/issues/6106.

## Solution

- Make the interface and type changes.  Avoid accessing `None`.
---

## Changelog

- Converted `raw_window_handle` field in both `Window` and `ExtractedWindow` to `Option<RawWindowHandleWrapper>`.
- Revised accessor function `Window::raw_window_handle()` to return `Option<RawWindowHandleWrapper>`.
- Skip conditions in loops that would require a raw window handle (to create a `Surface`, for example).

## Migration Guide

`Window::raw_window_handle()` now returns `Option<RawWindowHandleWrapper>`.


Co-authored-by: targrub <62773321+targrub@users.noreply.github.com>
2022-10-17 14:19:24 +00:00
..
converters.rs Rename ElementState to ButtonState (#4314) 2022-04-24 22:57:02 +00:00
lib.rs Change UI coordinate system to have origin at top left corner (#6000) 2022-10-11 12:51:44 +00:00
web_resize.rs Make Resource trait opt-in, requiring #[derive(Resource)] V2 (#5577) 2022-08-08 21:36:35 +00:00
winit_config.rs Make Resource trait opt-in, requiring #[derive(Resource)] V2 (#5577) 2022-08-08 21:36:35 +00:00
winit_windows.rs Make raw_window_handle field in Window and ExtractedWindow an Option. (#6114) 2022-10-17 14:19:24 +00:00