mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Refactor winit key handling
This commit is contained in:
parent
65df9cb73a
commit
3c7bb87e6d
4 changed files with 72 additions and 96 deletions
|
@ -367,10 +367,8 @@ impl<Window> Servo<Window> where Window: WindowMethods + 'static {
|
|||
|
||||
(EmbedderMsg::KeyEvent(ch, key, state, modified),
|
||||
ShutdownState::NotShuttingDown) => {
|
||||
if state == KeyState::Pressed {
|
||||
let event = (top_level_browsing_context, EmbedderMsg::KeyEvent(ch, key, state, modified));
|
||||
self.embedder_events.push(event);
|
||||
}
|
||||
let event = (top_level_browsing_context, EmbedderMsg::KeyEvent(ch, key, state, modified));
|
||||
self.embedder_events.push(event);
|
||||
},
|
||||
|
||||
(msg, ShutdownState::NotShuttingDown) => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue