diff options
| author | Kai Köhne <kai.koehne@qt.io> | 2025-07-29 15:41:57 +0200 |
|---|---|---|
| committer | Kai Köhne <kai.koehne@qt.io> | 2025-07-31 20:48:23 +0200 |
| commit | 1e367f2f8ccb95f9bdf93e3d6ddbb38ce2a9d13f (patch) | |
| tree | 43c94dacd81e5beb0a73a2766f72d56e46a5b191 /src | |
| parent | fc5fed5ec450286fb0e12b34ccedc55bb039995d (diff) | |
Hide warning on deprecated NSWindowStyleMaskTexturedBackground
The enum was deprecated in macOS 10.14. The warning does show up
in all Qt builds (-developer-build or not). Most users won't be
qualified to do anything about the warning, so let's hide it for
now.
Pick-to: 6.9 6.10
Task-number: QTBUG-138829
Change-Id: I08007164eecbac4dc9708a615f34462f6f8de852
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Diffstat (limited to 'src')
| -rw-r--r-- | src/plugins/platforms/cocoa/qcocoawindow.mm | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/plugins/platforms/cocoa/qcocoawindow.mm b/src/plugins/platforms/cocoa/qcocoawindow.mm index d0abb8e38c4..bca3c9b6f37 100644 --- a/src/plugins/platforms/cocoa/qcocoawindow.mm +++ b/src/plugins/platforms/cocoa/qcocoawindow.mm @@ -642,9 +642,9 @@ NSUInteger QCocoaWindow::windowStyleMask(Qt::WindowFlags flags) if (type == Qt::Tool) styleMask |= NSWindowStyleMaskUtilityWindow; - // FIXME: Remove use of deprecated style mask + // FIXME (QTBUG-138829) if (m_drawContentBorderGradient) - styleMask |= NSWindowStyleMaskTexturedBackground; + styleMask |= QT_IGNORE_DEPRECATIONS(NSWindowStyleMaskTexturedBackground); if (flags & Qt::ExpandedClientAreaHint) styleMask |= NSWindowStyleMaskFullSizeContentView; @@ -768,6 +768,7 @@ void QCocoaWindow::setWindowFlags(Qt::WindowFlags flags) if (m_view.window.ignoresMouseEvents != ignoreMouse) m_view.window.ignoresMouseEvents = ignoreMouse; + // FIXME (QTBUG-138829) m_view.window.titlebarAppearsTransparent = (flags & Qt::NoTitleBarBackgroundHint) || (m_view.window.styleMask & QT_IGNORE_DEPRECATIONS(NSWindowStyleMaskTexturedBackground)); } @@ -2055,7 +2056,8 @@ void QCocoaWindow::applyContentBorderThickness(NSWindow *window) return; if (!m_drawContentBorderGradient) { - window.styleMask = window.styleMask & ~NSWindowStyleMaskTexturedBackground; + // FIXME (QTBUG-138829) + window.styleMask = window.styleMask & QT_IGNORE_DEPRECATIONS(~NSWindowStyleMaskTexturedBackground); setWindowFlags(QPlatformWindow::window()->flags()); [window.contentView.superview setNeedsDisplay:YES]; return; @@ -2081,7 +2083,8 @@ void QCocoaWindow::applyContentBorderThickness(NSWindow *window) int effectiveBottomContentBorderThickness = 0; - [window setStyleMask:[window styleMask] | NSWindowStyleMaskTexturedBackground]; + // FIXME (QTBUG-138829) + [window setStyleMask:[window styleMask] | QT_IGNORE_DEPRECATIONS(NSWindowStyleMaskTexturedBackground)]; setWindowFlags(QPlatformWindow::window()->flags()); // Setting titlebarAppearsTransparent to YES means that the border thickness has to account |
