Fix unlocked TUI visibility and clipboard feedback
This commit is contained in:
@@ -227,6 +227,22 @@ impl AsyncExecutor {
|
||||
}
|
||||
}
|
||||
|
||||
pub fn clipboard_started_reporter(
|
||||
&self,
|
||||
token: RequestToken,
|
||||
) -> impl Fn(crate::app::ClipboardPresentationId, std::time::Instant) + Send + 'static {
|
||||
let sender = self.sender.clone();
|
||||
move |presentation, deadline| {
|
||||
let _ignored = sender.send(AsyncResult {
|
||||
token,
|
||||
payload: Ok(AsyncPayload::ClipboardStarted {
|
||||
presentation,
|
||||
deadline,
|
||||
}),
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
pub fn drain(&self) -> impl Iterator<Item = AsyncResult> + '_ {
|
||||
self.receiver.try_iter()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user