diff --git a/src/server/domain.rs b/src/server/domain.rs index 2aa308026..f5ca0951e 100644 --- a/src/server/domain.rs +++ b/src/server/domain.rs @@ -179,7 +179,7 @@ impl Domain for ClientDomain { result.tab_id }; - let tab: Rc = Rc::new(ClientTab::new(&inner, remote_tab_id, size)); + let tab: Rc = Rc::new(ClientTab::new(&inner, remote_tab_id, size, "wezterm")); let mux = Mux::get().unwrap(); mux.add_tab(&tab)?; mux.add_tab_to_window(&tab, window)?; @@ -211,7 +211,12 @@ impl Domain for ClientDomain { entry.window_id, entry.title ); - let tab: Rc = Rc::new(ClientTab::new(&inner, entry.tab_id, entry.size)); + let tab: Rc = Rc::new(ClientTab::new( + &inner, + entry.tab_id, + entry.size, + &entry.title, + )); mux.add_tab(&tab)?; if let Some(local_window_id) = inner.remote_to_local_window(entry.window_id) { diff --git a/src/server/tab.rs b/src/server/tab.rs index cc3f0b056..6e29caee5 100644 --- a/src/server/tab.rs +++ b/src/server/tab.rs @@ -128,7 +128,12 @@ pub struct ClientTab { } impl ClientTab { - pub fn new(client: &Arc, remote_tab_id: TabId, size: PtySize) -> Self { + pub fn new( + client: &Arc, + remote_tab_id: TabId, + size: PtySize, + title: &str, + ) -> Self { let local_tab_id = alloc_tab_id(); let writer = TabWriter { client: Arc::clone(client), @@ -161,7 +166,7 @@ impl ClientTab { scrollback_top: 0, }, lines: LruCache::unbounded(), - title: "wezterm".to_string(), + title: title.to_string(), }), };