bevy/crates/bevy_dev_tools/src
Mateusz Wachowiak 6ccb2a306e
remove close_on_esc (#12859)
# Objective

- Remove `close_on_esc`
- For context about why we are removing it see:
[discord](https://discordapp.com/channels/691052431525675048/692572690833473578/1225075194524073985)

## Migration Guide

- Users who added `close_on_esc` in their application will have to
replace it with their own solution.

```rust
pub fn close_on_esc(
    mut commands: Commands,
    focused_windows: Query<(Entity, &Window)>,
    input: Res<ButtonInput<KeyCode>>,
) {
    for (window, focus) in focused_windows.iter() {
        if !focus.focused {
            continue;
        }

        if input.just_pressed(KeyCode::Escape) {
            commands.entity(window).despawn();
        }
    }
}
```
2024-04-03 18:02:50 +00:00
..
ui_debug_overlay rename debug_overlay to ui_debug_overlay in bevy_dev_tools (#12737) 2024-03-26 19:40:55 +00:00
ci_testing.rs Refactor App and SubApp internals for better separation (#9202) 2024-03-31 03:16:10 +00:00
fps_overlay.rs Always spawn fps_overlay on top of everything (#12586) 2024-03-20 13:11:48 +00:00
lib.rs remove close_on_esc (#12859) 2024-04-03 18:02:50 +00:00