Fix negative cursor movement

I noticed moving-up does not work and tracked it down here.
This commit is contained in:
Jun Wu authored and Wez Furlong committed 2020-01-05 14:18:08 -08:00
1 parent ef1b836441
commit 318267c88b
1 file changed
+2 -2
+2 -2
View File
@@ -450,13 +450,13 @@ impl TerminfoRenderer {
x: Position::NoChange,
y: Position::Relative(n),
} if *n < 0 => {
self.cursor_up(*n as u32, out)?;
self.cursor_up(-*n as u32, out)?;
}
Change::CursorPosition {
x: Position::Relative(n),
y: Position::NoChange,
} if *n < 0 => {
self.cursor_left(*n as u32, out)?;
self.cursor_left(-*n as u32, out)?;
}
Change::CursorPosition {
x: Position::Relative(n),