Fix title setting via IPC when dynamic_title is enabled

This commit is contained in:
Kirill Chibisov 2022-01-06 02:13:55 +03:00 committed by GitHub
parent f7177101ed
commit db83902319
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 1 deletions

View File

@ -186,6 +186,7 @@ pub struct ActionContext<'a, N, T> {
pub search_state: &'a mut SearchState,
pub font_size: &'a mut Size,
pub dirty: &'a mut bool,
pub preserve_title: bool,
#[cfg(not(windows))]
pub master_fd: RawFd,
#[cfg(not(windows))]
@ -1039,7 +1040,7 @@ impl input::Processor<EventProxy, ActionContext<'_, Notifier, EventProxy>> {
},
EventType::Terminal(event) => match event {
TerminalEvent::Title(title) => {
if self.ctx.config.window.dynamic_title {
if !self.ctx.preserve_title && self.ctx.config.window.dynamic_title {
self.ctx.window().set_title(title);
}
},

View File

@ -280,6 +280,7 @@ impl WindowContext {
master_fd: self.master_fd,
#[cfg(not(windows))]
shell_pid: self.shell_pid,
preserve_title: self.preserve_title,
event_proxy,
event_loop,
clipboard,