summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/cocoa/qnswindow.mm
diff options
context:
space:
mode:
authorPaul Wicking <paul.wicking@qt.io>2019-08-23 08:42:17 +0200
committerPaul Wicking <paul.wicking@qt.io>2019-08-23 08:42:17 +0200
commit304587e3dbb46d23180075bf20cebf7bc342a313 (patch)
treecb67b5128ce9debc42aeaa172dab6f53244d3855 /src/plugins/platforms/cocoa/qnswindow.mm
parent28ba681eb6f53ec817b191f3d8ff62ffe282bac5 (diff)
parentb1db1dd655788fb685949959c99c901515bfd8ab (diff)
Merge 5.12 into 5.12.5
Diffstat (limited to 'src/plugins/platforms/cocoa/qnswindow.mm')
-rw-r--r--src/plugins/platforms/cocoa/qnswindow.mm14
1 files changed, 2 insertions, 12 deletions
diff --git a/src/plugins/platforms/cocoa/qnswindow.mm b/src/plugins/platforms/cocoa/qnswindow.mm
index 52f765eb31..68cb270457 100644
--- a/src/plugins/platforms/cocoa/qnswindow.mm
+++ b/src/plugins/platforms/cocoa/qnswindow.mm
@@ -253,20 +253,10 @@ static bool isMouseEvent(NSEvent *ev)
return m_platformWindow ? m_platformWindow->isOpaque() : [super isOpaque];
}
-/*!
- Borderless windows need a transparent background
-
- Technically windows with NSWindowStyleMaskTexturedBackground
- (such as windows with unified toolbars) need to draw the textured
- background of the NSWindow, and can't have a transparent
- background, but as NSWindowStyleMaskBorderless is 0, you can't
- have a window with NSWindowStyleMaskTexturedBackground that is
- also borderless.
-*/
- (NSColor *)backgroundColor
{
- return self.styleMask == NSWindowStyleMaskBorderless
- ? [NSColor clearColor] : [super backgroundColor];
+ return self.styleMask & NSWindowStyleMaskTexturedBackground ?
+ [super backgroundColor] : [NSColor clearColor];
}
- (void)sendEvent:(NSEvent*)theEvent