From 539ebf049a59d1f5316a520f736c21a387065082 Mon Sep 17 00:00:00 2001 From: "trop[bot]" <37223003+trop[bot]@users.noreply.github.com> Date: Mon, 11 Sep 2023 09:35:10 +0200 Subject: [PATCH] fix: make titlebar opaque while fullscreen (#39781) Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com> Co-authored-by: Samuel Attard --- shell/browser/native_window_mac.mm | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/shell/browser/native_window_mac.mm b/shell/browser/native_window_mac.mm index 0d1eadd1304bb..f9b162a6f350f 100644 --- a/shell/browser/native_window_mac.mm +++ b/shell/browser/native_window_mac.mm @@ -1696,6 +1696,9 @@ void ReorderChildWindowAbove(NSWindow* child_window, NSWindow* other_window) { // Restore the window title under fullscreen mode. if (buttons_proxy_) [window_ setTitleVisibility:NSWindowTitleVisible]; + + if (transparent() || !has_frame()) + [window_ setTitlebarAppearsTransparent:NO]; } void NativeWindowMac::NotifyWindowLeaveFullScreen() { @@ -1705,6 +1708,9 @@ void ReorderChildWindowAbove(NSWindow* child_window, NSWindow* other_window) { [buttons_proxy_ redraw]; [buttons_proxy_ setVisible:YES]; } + + if (transparent() || !has_frame()) + [window_ setTitlebarAppearsTransparent:YES]; } void NativeWindowMac::NotifyWindowWillEnterFullScreen() {