diff options
author | Christian Duerr <contact@christianduerr.com> | 2018-03-09 23:02:45 +0100 |
---|---|---|
committer | Joe Wilm <jwilm@users.noreply.github.com> | 2018-03-13 14:52:14 -0700 |
commit | a741193bc0f96595e8b618322440669125bf08a6 (patch) | |
tree | dd2cb9f852e473e37bd28d6fcac12aa3dc8f1464 /src/input.rs | |
parent | c1e831dab03bd1a48d2aa0f383aa5aaea2b3632b (diff) | |
download | alacritty-a741193bc0f96595e8b618322440669125bf08a6.tar.gz alacritty-a741193bc0f96595e8b618322440669125bf08a6.zip |
Fix linux config default value
Diffstat (limited to 'src/input.rs')
-rw-r--r-- | src/input.rs | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/input.rs b/src/input.rs index 9b9aedc3..f1e63299 100644 --- a/src/input.rs +++ b/src/input.rs @@ -398,7 +398,7 @@ impl<'a, A: ActionContext + 'a> Processor<'a, A> { 65 }; - let scrolling_multiplier = self.mouse_config.normal_scrolling_lines; + let scrolling_multiplier = self.scrolling_config.multiplier; for _ in 0..(to_scroll.abs() as usize) { self.scroll_terminal(mouse_modes, code, modifiers, scrolling_multiplier) } @@ -436,7 +436,11 @@ impl<'a, A: ActionContext + 'a> Processor<'a, A> { fn scroll_terminal(&mut self, mouse_modes: TermMode, code: u8, modifiers: ModifiersState, scroll_multiplier: u8) { debug_assert!(code == 64 || code == 65); - let faux_scrollback_lines = self.mouse_config.faux_scrollback_lines as usize; + // Make sure the new and deprecated setting are both allowed + let faux_scrollback_lines = self.mouse_config + .faux_scrollback_lines + .unwrap_or(self.scrolling_config.faux_multiplier as usize); + if self.ctx.terminal_mode().intersects(mouse_modes) { self.mouse_report(code, ElementState::Pressed); } else if self.ctx.terminal_mode().contains(TermMode::ALT_SCREEN) |