aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/input.rs5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/input.rs b/src/input.rs
index 92126387..e6dc3993 100644
--- a/src/input.rs
+++ b/src/input.rs
@@ -285,6 +285,11 @@ impl<'a, A: ActionContext + 'a> Processor<'a, A> {
}
pub fn on_mouse_wheel(&mut self, delta: MouseScrollDelta, phase: TouchPhase) {
+ let modes = mode::MOUSE_REPORT_CLICK | mode::MOUSE_MOTION | mode::SGR_MOUSE;
+ if !self.ctx.terminal_mode().intersects(modes) {
+ return;
+ }
+
match delta {
MouseScrollDelta::LineDelta(_columns, lines) => {
let code = if lines > 0.0 {