aboutsummaryrefslogtreecommitdiff
path: root/helix-term/src/ui/picker.rs
diff options
context:
space:
mode:
authorBlaž Hrastnik2021-05-29 01:37:47 +0000
committerBlaž Hrastnik2021-05-29 01:37:47 +0000
commitd54ae09d3b7a5eb56050631a58e75a1d1686ea70 (patch)
tree89f8c5079c43f026156d756df6c0325fe16083bc /helix-term/src/ui/picker.rs
parenta28eaa81a0c5fede1e34aca5bbf70d411f7a174b (diff)
ESC should exit both completion and insert mode
Diffstat (limited to 'helix-term/src/ui/picker.rs')
-rw-r--r--helix-term/src/ui/picker.rs6
1 files changed, 2 insertions, 4 deletions
diff --git a/helix-term/src/ui/picker.rs b/helix-term/src/ui/picker.rs
index a715ebb5..4cff4917 100644
--- a/helix-term/src/ui/picker.rs
+++ b/helix-term/src/ui/picker.rs
@@ -122,14 +122,12 @@ fn inner_rect(area: Rect) -> Rect {
let padding_vertical = area.height * 20 / 100;
let padding_horizontal = area.width * 20 / 100;
- let area = Rect::new(
+ Rect::new(
area.x + padding_horizontal,
area.y + padding_vertical,
area.width - padding_horizontal * 2,
area.height - padding_vertical * 2,
- );
-
- area
+ )
}
impl<T: 'static> Component for Picker<T> {