summaryrefslogtreecommitdiff
path: root/helix-term/src/ui/prompt.rs
diff options
context:
space:
mode:
authorBram2022-02-23 03:46:12 +0000
committerGitHub2022-02-23 03:46:12 +0000
commit40eb1268c72b60f1249389c58892e7c45d268cff (patch)
tree84f741c7067547b4af3e6b0a867c10639d00ede8 /helix-term/src/ui/prompt.rs
parente1a92fd3998aca2a313d4cbf0aca3157eca0b53f (diff)
Close some popups automatically (#1285)
* Add Event::Used to use event callback without consuming * Close popup if contents ignored event * collect event results before executing callbacks * don't add new result variant, use Ignored(..) instead * break in match cases * Make auto_close configurable * fix merge * auto close hover popups * fix formatting
Diffstat (limited to 'helix-term/src/ui/prompt.rs')
-rw-r--r--helix-term/src/ui/prompt.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/helix-term/src/ui/prompt.rs b/helix-term/src/ui/prompt.rs
index cd8e14ee..c3402f02 100644
--- a/helix-term/src/ui/prompt.rs
+++ b/helix-term/src/ui/prompt.rs
@@ -438,7 +438,7 @@ impl Component for Prompt {
let event = match event {
Event::Key(event) => event,
Event::Resize(..) => return EventResult::Consumed(None),
- _ => return EventResult::Ignored,
+ _ => return EventResult::Ignored(None),
};
let close_fn = EventResult::Consumed(Some(Box::new(|compositor: &mut Compositor, _| {