avoid using unimplemented input method

pull/535/head
tomoki maekawa 3 months ago committed by GitHub
parent 2bb2f8373b
commit 59c582ccc8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -327,21 +327,19 @@ We call this method `run()` in the event loop for the following events.
```rust
match event {
// ...
} if window_id == state.window().id() => match event {
// ...
} if window_id == state.window().id() => if !state.input(event) {
match event {
// ...
WindowEvent::Resized(physical_size) => {
state.resize(*physical_size);
}
WindowEvent::ScaleFactorChanged { new_inner_size, .. } => {
// new_inner_size is &&mut so we have to dereference it twice
state.resize(**new_inner_size);
}
// ...
WindowEvent::Resized(physical_size) => {
state.resize(*physical_size);
}
WindowEvent::ScaleFactorChanged { new_inner_size, .. } => {
// new_inner_size is &&mut so we have to dereference it twice
state.resize(**new_inner_size);
}
// ...
}
// ...
}
```

Loading…
Cancel
Save