From c1664b348d97d6ab1a1a6956e1823ca70e64351c Mon Sep 17 00:00:00 2001 From: Christian Duerr Date: Tue, 14 Jan 2020 17:01:43 +0100 Subject: Remove synthetic keyboard event handling Fixes #3109. --- alacritty/src/event.rs | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'alacritty/src') diff --git a/alacritty/src/event.rs b/alacritty/src/event.rs index 87f4d627..7f5e385b 100644 --- a/alacritty/src/event.rs +++ b/alacritty/src/event.rs @@ -527,7 +527,7 @@ impl Processor { processor.ctx.display_update_pending.dimensions = Some(size); processor.ctx.terminal.dirty = true; }, - KeyboardInput { input, .. } => { + KeyboardInput { input, is_synthetic: false, .. } => { processor.key_input(input); if input.state == ElementState::Pressed { // Hide cursor while typing @@ -581,7 +581,8 @@ impl Processor { processor.ctx.terminal.dirty = true; } }, - TouchpadPressure { .. } + KeyboardInput { is_synthetic: true, .. } + | TouchpadPressure { .. } | ScaleFactorChanged { .. } | CursorEntered { .. } | AxisMotion { .. } @@ -614,7 +615,8 @@ impl Processor { GlutinEvent::WindowEvent { event, .. } => { use glutin::event::WindowEvent::*; match event { - TouchpadPressure { .. } + KeyboardInput { is_synthetic: true, .. } + | TouchpadPressure { .. } | CursorEntered { .. } | AxisMotion { .. } | HoveredFileCancelled -- cgit