diff options
author | Teddy Wing | 2016-08-06 04:49:10 -0400 |
---|---|---|
committer | Teddy Wing | 2016-08-06 04:49:10 -0400 |
commit | f4b7600f28e5d056569424aaa83e05127e1a0816 (patch) | |
tree | 9b506dbf3a97e5ffb43af8cff46f37d0aa53d9cf /src | |
parent | c7fcf123499050a6b187ed7e5448fa88d92dc60b (diff) | |
download | Passextract-f4b7600f28e5d056569424aaa83e05127e1a0816.tar.bz2 |
Remove `set_cursor` calls
Don't move the cursor when the selection is changed. It was flickering,
which looked rather distracting. Removing the cursor makes the interface
look more fluid and snappy.
Diffstat (limited to 'src')
-rw-r--r-- | src/main.rs | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/src/main.rs b/src/main.rs index ce0f4fe..f0cb840 100644 --- a/src/main.rs +++ b/src/main.rs @@ -58,8 +58,6 @@ fn main() { term.printline(5, i + 3, s) } - term.set_cursor(selection.x + 2, selection.y).unwrap(); - let evt = term.get_event(Duration::from_millis(100)).unwrap(); if let Some(Event::Key(ch)) = evt { match ch { @@ -73,7 +71,6 @@ fn main() { selection.y = selection.y + 1; term.printline_with_cell(selection.x, selection.y, "->", knockout_cell); - term.set_cursor(selection.x + 2, selection.y).unwrap(); } } 'k' => { @@ -83,7 +80,6 @@ fn main() { selection.y = selection.y - 1; term.printline_with_cell(selection.x, selection.y, "->", knockout_cell); - term.set_cursor(selection.x + 2, selection.y).unwrap(); } } '\x0D' => { |