diff --git a/CHANGELOG.md b/CHANGELOG.md index 1f99c9d9f739..0319dd1f6af1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,12 @@ All notable changes to cmux are documented here. +## [1.26.0] - 2026-02-11 + +### Fixed +- Muted traffic lights and toolbar items in focused window caused by background blur in themeFrame +- Sidebar showing two different textures near the titlebar on older macOS versions + ## [1.25.0] - 2026-02-11 ### Fixed diff --git a/GhosttyTabs.xcodeproj/project.pbxproj b/GhosttyTabs.xcodeproj/project.pbxproj index 0fc6733e43f3..0ab4e3817559 100644 --- a/GhosttyTabs.xcodeproj/project.pbxproj +++ b/GhosttyTabs.xcodeproj/project.pbxproj @@ -538,7 +538,7 @@ CODE_SIGN_ENTITLEMENTS = ""; CODE_SIGN_STYLE = Automatic; COMBINE_HIDPI_IMAGES = YES; - CURRENT_PROJECT_VERSION = 36; + CURRENT_PROJECT_VERSION = 37; DEVELOPMENT_TEAM = ""; ENABLE_HARDENED_RUNTIME = NO; GENERATE_INFOPLIST_FILE = YES; @@ -554,7 +554,7 @@ "$(inherited)", "@executable_path/../Frameworks", ); - MARKETING_VERSION = 1.25.0; + MARKETING_VERSION = 1.26.0; OTHER_LDFLAGS = ( "-lc++", "-framework", @@ -583,7 +583,7 @@ CODE_SIGN_ENTITLEMENTS = ""; CODE_SIGN_STYLE = Automatic; COMBINE_HIDPI_IMAGES = YES; - CURRENT_PROJECT_VERSION = 36; + CURRENT_PROJECT_VERSION = 37; DEVELOPMENT_TEAM = ""; ENABLE_HARDENED_RUNTIME = NO; GENERATE_INFOPLIST_FILE = YES; @@ -599,7 +599,7 @@ "$(inherited)", "@executable_path/../Frameworks", ); - MARKETING_VERSION = 1.25.0; + MARKETING_VERSION = 1.26.0; OTHER_LDFLAGS = ( "-lc++", "-framework", @@ -652,10 +652,10 @@ isa = XCBuildConfiguration; buildSettings = { CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 36; + CURRENT_PROJECT_VERSION = 37; GENERATE_INFOPLIST_FILE = YES; MACOSX_DEPLOYMENT_TARGET = 13.0; - MARKETING_VERSION = 1.25.0; + MARKETING_VERSION = 1.26.0; ONLY_ACTIVE_ARCH = YES; PRODUCT_BUNDLE_IDENTIFIER = com.cmux.appuitests; PRODUCT_NAME = "$(TARGET_NAME)"; @@ -669,10 +669,10 @@ isa = XCBuildConfiguration; buildSettings = { CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 36; + CURRENT_PROJECT_VERSION = 37; GENERATE_INFOPLIST_FILE = YES; MACOSX_DEPLOYMENT_TARGET = 13.0; - MARKETING_VERSION = 1.25.0; + MARKETING_VERSION = 1.26.0; ONLY_ACTIVE_ARCH = YES; PRODUCT_BUNDLE_IDENTIFIER = com.cmux.appuitests; PRODUCT_NAME = "$(TARGET_NAME)"; diff --git a/Sources/ContentView.swift b/Sources/ContentView.swift index ed2e98f6de82..9843269c1e70 100644 --- a/Sources/ContentView.swift +++ b/Sources/ContentView.swift @@ -2,6 +2,17 @@ import AppKit import SwiftUI import ObjectiveC +/// NSVisualEffectView that never intercepts mouse events. Used for background +/// blur inside contentView where SwiftUI may reorder it above interactive content. +private class PassthroughBlurView: NSVisualEffectView { + override func hitTest(_ point: NSPoint) -> NSView? { nil } +} + +/// Plain NSView that never intercepts mouse events. Used for tint overlays. +private class PassthroughView: NSView { + override func hitTest(_ point: NSPoint) -> NSView? { nil } +} + /// Applies NSGlassEffectView (macOS 26+) to a window, falling back to NSVisualEffectView enum WindowGlassEffect { private static var glassViewKey: UInt8 = 0 @@ -44,33 +55,29 @@ enum WindowGlassEffect { return } - // Older macOS: insert blur below the contentView in the window's internal view - // hierarchy. Adding to contentView directly gets reordered by SwiftUI, causing - // the blur view to cover the terminal content. - let blurView = NSVisualEffectView(frame: bounds) + // Older macOS: insert blur and tint inside contentView with a deeply + // negative zPosition so they always render behind SwiftUI content even + // if SwiftUI reorders the subview list. PassthroughBlurView overrides + // hitTest to avoid intercepting mouse events when SwiftUI moves it to + // a higher subview index. + let blurView = PassthroughBlurView(frame: bounds) blurView.blendingMode = .behindWindow blurView.material = .hudWindow blurView.state = .active blurView.wantsLayer = true blurView.autoresizingMask = [.width, .height] + blurView.layer?.zPosition = -1000 - if let themeFrame = contentView.superview { - themeFrame.addSubview(blurView, positioned: .below, relativeTo: contentView) - } else { - contentView.addSubview(blurView, positioned: .below, relativeTo: contentView.subviews.first) - } + contentView.addSubview(blurView, positioned: .below, relativeTo: contentView.subviews.first) // Tint overlay on top of blur, still behind content if let color = tintColor { - let tintOverlay = NSView(frame: bounds) + let tintOverlay = PassthroughView(frame: bounds) tintOverlay.autoresizingMask = [.width, .height] tintOverlay.wantsLayer = true tintOverlay.layer?.backgroundColor = color.cgColor - if let themeFrame = contentView.superview { - themeFrame.addSubview(tintOverlay, positioned: .above, relativeTo: blurView) - } else { - contentView.addSubview(tintOverlay, positioned: .above, relativeTo: blurView) - } + tintOverlay.layer?.zPosition = -999 + contentView.addSubview(tintOverlay, positioned: .above, relativeTo: blurView) objc_setAssociatedObject(window, &tintOverlayKey, tintOverlay, .OBJC_ASSOCIATION_RETAIN) } diff --git a/docs-site/content/docs/changelog.mdx b/docs-site/content/docs/changelog.mdx index 31fa33b3bb2e..03aaadfbde3f 100644 --- a/docs-site/content/docs/changelog.mdx +++ b/docs-site/content/docs/changelog.mdx @@ -5,6 +5,12 @@ description: Release notes and version history for cmux All notable changes to cmux are documented here. +## [1.26.0] - 2026-02-11 + +### Fixed +- Muted traffic lights and toolbar items in focused window caused by background blur in themeFrame +- Sidebar showing two different textures near the titlebar on older macOS versions + ## [1.25.0] - 2026-02-11 ### Fixed