aboutsummaryrefslogtreecommitdiff
path: root/src/input.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/input.rs')
-rw-r--r--src/input.rs26
1 files changed, 13 insertions, 13 deletions
diff --git a/src/input.rs b/src/input.rs
index f2bd461b..47ce52fa 100644
--- a/src/input.rs
+++ b/src/input.rs
@@ -209,11 +209,10 @@ impl<'a, N: Notify + 'a> Processor<'a, N> {
line: point.line,
col: point.col
}, self.ctx.mouse.cell_side);
- } else if self.ctx.terminal.mode().contains(mode::MOUSE_MOTION) {
- // Only report motion when changing cells
- if prev_line != self.ctx.mouse.line || prev_col != self.ctx.mouse.column {
- self.mouse_report(0 + 32);
- }
+ } else if self.ctx.terminal.mode().contains(mode::MOUSE_MOTION)
+ // Only report motion when changing cells
+ && (prev_line != self.ctx.mouse.line || prev_col != self.ctx.mouse.column) {
+ self.mouse_report(32);
}
}
}
@@ -364,16 +363,17 @@ impl<'a, N: Notify + 'a> Processor<'a, N> {
return;
}
- // Didn't process a binding; print the provided character
- if let Some(mut string) = string {
- // from ST
- if string.len() == 1 && mods.contains(mods::ALT) {
- string.insert(0, '\x1b');
- }
+ }
- self.ctx.notifier.notify(string.into_bytes());
- self.ctx.selection.clear();
+ // Didn't process a binding; print the provided character
+ if let Some(mut string) = string {
+ // from ST
+ if string.len() == 1 && mods.contains(mods::ALT) {
+ string.insert(0, '\x1b');
}
+
+ self.ctx.notifier.notify(string.into_bytes());
+ self.ctx.selection.clear();
}
}