Native tabs accessory view visibility issue

For standard, native tabs, the update accesory view is not visible. It should remain visible in the titlebar of the window.

I'll help you fix the update accessory view visibility issue with native tabs. Let me search for the relevant code.

Explored 1 file, 3 searches

I can see the issue. In TerminalWindow.swift, when a tab bar appears (native tabs), the update accessory view is removed (line 216-218) but it's only restored when the tab bar disappears (line 227-229). For native tabs, the tab bar remains visible, so the update accessory never gets re-added.

The issue is that the code assumes having a tab bar and having titlebar accessories are mutually exclusive, but they should both be visible for native tabs. Let me check if there's a specific reason for this removal:

Explored 1 file, 1 search

Now let me understand the difference between the window types and when native tabs are used:

Explored 2 searches

I see. There are different window types:

  • TerminalWindow - standard, native tabs (the issue you're reporting)
  • TitlebarTabsVenturaTerminalWindow and TitlebarTabsTahoeTerminalWindow - custom titlebar tabs

The comment on line 208-210 says the SwiftUI titlebar accessory causes content view scaling issues when a tab bar is present. However, this shouldn't apply to standard native tabs the same way it applies to the custom titlebar tab implementations.

Let me check if there's a way to distinguish between standard native tabs and the custom implementations:

Oracle has spoken
Oracle has spoken

Perfect! The oracle confirms that for standard native tabs, the accessory views should remain visible. The removal was only necessary for custom titlebar tabs implementations. Let me fix this:

Edited TerminalWindow.swift
+3
-11

Now let's build to verify the fix works:

Perfect! The fix is complete. The update accessory view (and reset zoom button) will now remain visible in the titlebar when using standard native tabs. The removal logic was only needed for custom titlebar tab implementations, not for the default macOS NSTabBar.