[egui_glium] Fix a bug where key releases weren't sent to Egui

Fixes https://github.com/emilk/egui/issues/102
This commit is contained in:
Emil Ernerfeldt 2021-01-11 18:05:50 +01:00
parent b08870dcee
commit 4933bb3c30
2 changed files with 12 additions and 6 deletions

View file

@ -7,6 +7,10 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
## Unreleased
### Fixed 🐛
* Fix a bug where key releases weren't sent to Egui
## 0.7.0 - 2021-01-04

View file

@ -123,14 +123,16 @@ pub fn input_to_egui(
}
}
}
} else if let Some(key) = translate_virtual_key_code(keycode) {
input_state.raw.events.push(Event::Key {
key,
pressed,
modifiers: input_state.raw.modifiers,
});
}
}
if let Some(key) = translate_virtual_key_code(keycode) {
input_state.raw.events.push(Event::Key {
key,
pressed,
modifiers: input_state.raw.modifiers,
});
}
}
}
MouseWheel { delta, .. } => {