Skip to content

Commit 372d6df

Browse files
author
Tom Poole
committed
MacOS: Fixed an issue with transparent windows on Mojave
1 parent a44d3d7 commit 372d6df

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

modules/juce_gui_basics/native/juce_mac_NSViewComponentPeer.mm

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,14 @@ static NSRect flippedScreenRect (NSRect r) noexcept
116116
#else
117117
[window setDelegate: window];
118118
#endif
119+
119120
[window setOpaque: component.isOpaque()];
121+
122+
#if defined (MAC_OS_X_VERSION_10_14)
123+
if (! [window isOpaque])
124+
[window setBackgroundColor: [NSColor clearColor]];
125+
#endif
126+
120127
[window setHasShadow: ((windowStyleFlags & windowHasDropShadow) != 0)];
121128

122129
if (component.isAlwaysOnTop())

0 commit comments

Comments
 (0)