summaryrefslogtreecommitdiff
path: root/src/app/api.rs
diff options
context:
space:
mode:
authorakbash <akbash@herdr.dev>2026-08-08 02:15:56 +0300
committerGitHub <noreply@github.com>2026-08-08 02:15:56 +0300
commit6f311498aeeb27c0973781961ef94e8d0016ed17 (patch)
tree7aee2363b21b830fdbcf8dca9a7eda57a3393fb5 /src/app/api.rs
parent50ddc06f00ec69ede35fd5488a260dec2b74e98a (diff)
fix: forward pane terminal bells (#2498)
refs #2453 Co-authored-by: akbash-bot <300245827+akbash-bot@users.noreply.github.com>
Diffstat (limited to 'src/app/api.rs')
-rw-r--r--src/app/api.rs13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/app/api.rs b/src/app/api.rs
index 5f81a5cb..c2130f36 100644
--- a/src/app/api.rs
+++ b/src/app/api.rs
@@ -64,6 +64,10 @@ impl App {
results,
cache_updates,
} => self.handle_git_status_refreshed(results, cache_updates),
+ ev @ AppEvent::TerminalBell { .. } => {
+ self.handle_internal_event(ev);
+ false
+ }
ev => {
self.handle_internal_event(ev);
true
@@ -97,6 +101,15 @@ impl App {
}
pub(crate) fn handle_internal_event(&mut self, ev: AppEvent) {
+ if let AppEvent::TerminalBell { count, .. } = ev {
+ if let Err(err) =
+ crate::terminal_effects::write_terminal_bells(&mut std::io::stdout(), count)
+ {
+ tracing::warn!(err = %err, "failed to emit terminal bell");
+ }
+ return;
+ }
+
if let AppEvent::ClipboardWrite { content } = ev {
#[cfg(not(test))]
crate::selection::write_osc52_bytes(&content);