Distinguish local and SSH tabs by color and hostname
Replace the window-wide connection badge with purple local tabs and teal SSH tabs. Show the SSH hostname below the remote tab title, including during tab renaming.
This commit is contained in:
+5
-4
@@ -38,7 +38,6 @@ struct TabRename {
|
||||
|
||||
pub struct Workspace {
|
||||
client: Client,
|
||||
connection: SharedString,
|
||||
font: TerminalFont,
|
||||
snapshot: Option<Arc<Snapshot>>,
|
||||
panes: HashMap<u64, Entity<TerminalPane>>,
|
||||
@@ -328,7 +327,6 @@ impl Workspace {
|
||||
pub fn new(
|
||||
client: Client,
|
||||
updates: Updates,
|
||||
connection: SharedString,
|
||||
window: &mut Window,
|
||||
cx: &mut Context<Self>,
|
||||
) -> Self {
|
||||
@@ -479,7 +477,6 @@ impl Workspace {
|
||||
});
|
||||
Self {
|
||||
client,
|
||||
connection,
|
||||
font,
|
||||
snapshot: None,
|
||||
panes: HashMap::new(),
|
||||
@@ -529,6 +526,11 @@ impl Render for Workspace {
|
||||
.map(|tab| chrome::ChromeTab {
|
||||
id: tab.id,
|
||||
label: tab.title.clone().into(),
|
||||
remote: tab
|
||||
.remote
|
||||
.as_deref()
|
||||
.or(self.client.remote())
|
||||
.map(str::to_owned),
|
||||
active: tab.id == s.active_tab,
|
||||
editor: self
|
||||
.tab_rename
|
||||
@@ -542,7 +544,6 @@ impl Render for Workspace {
|
||||
let client = self.client.clone();
|
||||
let new_client = self.client.clone();
|
||||
let header = chrome::header(
|
||||
self.connection.clone(),
|
||||
tabs,
|
||||
cfg!(target_os = "macos") && !window.is_fullscreen(),
|
||||
move |tab, _, _| {
|
||||
|
||||
Reference in New Issue
Block a user