mirror of
https://github.com/sxyazi/yazi.git
synced 2026-07-24 16:21:04 +00:00
18 lines
356 B
Rust
18 lines
356 B
Rust
use yazi_shared::{emit, event::Cmd, Layer};
|
|
|
|
pub struct CompletionProxy;
|
|
|
|
impl CompletionProxy {
|
|
#[inline]
|
|
pub fn close() {
|
|
emit!(Call(Cmd::new("close"), Layer::Completion));
|
|
}
|
|
|
|
#[inline]
|
|
pub fn trigger(word: &str, ticket: usize) {
|
|
emit!(Call(
|
|
Cmd::args("trigger", vec![word.to_owned()]).with("ticket", ticket),
|
|
Layer::Completion
|
|
));
|
|
}
|
|
}
|