diff options
author | Tor Arne Vestbø <tor.arne.vestbo@qt.io> | 2016-10-05 20:56:38 +0200 |
---|---|---|
committer | Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com> | 2016-10-05 19:37:17 +0000 |
commit | 89842b97d74d1824240d3cc35950c92aa011a8ac (patch) | |
tree | 2abff407aa26e6cbc07c0ec75b0eed0ebe8cf479 /src/plugins/platforms/cocoa/qcocoanativeinterface.mm | |
parent | 087b11e881032bbd7bc1cbc06c45480c22ecb714 (diff) |
Implement QMacCocoaViewContainer in terms of foreign window
This leaves a clearer separation between the foreign-window and non-foreign
window use-cases, where a single QCococaWindow can only be in one mode,
which is determined in the constructor and doesn't change after that.
There are no source or binary compatibility guarantees for the QPA classes,
meaning the helper function in QPlatformNativeInterface can be removed.
Change-Id: I3232aedca1d98c49a8f54e16750832187f9dc69a
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Diffstat (limited to 'src/plugins/platforms/cocoa/qcocoanativeinterface.mm')
-rw-r--r-- | src/plugins/platforms/cocoa/qcocoanativeinterface.mm | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/src/plugins/platforms/cocoa/qcocoanativeinterface.mm b/src/plugins/platforms/cocoa/qcocoanativeinterface.mm index 71d0cccde1..10435d0b1d 100644 --- a/src/plugins/platforms/cocoa/qcocoanativeinterface.mm +++ b/src/plugins/platforms/cocoa/qcocoanativeinterface.mm @@ -125,8 +125,6 @@ QPlatformNativeInterface::NativeResourceForIntegrationFunction QCocoaNativeInter return NativeResourceForIntegrationFunction(QCocoaNativeInterface::qImageToCGImage); if (resource.toLower() == "cgimagetoqimage") return NativeResourceForIntegrationFunction(QCocoaNativeInterface::cgImageToQImage); - if (resource.toLower() == "setwindowcontentview") - return NativeResourceForIntegrationFunction(QCocoaNativeInterface::setWindowContentView); if (resource.toLower() == "registertouchwindow") return NativeResourceForIntegrationFunction(QCocoaNativeInterface::registerTouchWindow); if (resource.toLower() == "setembeddedinforeignview") @@ -278,12 +276,6 @@ QImage QCocoaNativeInterface::cgImageToQImage(CGImageRef image) return qt_mac_toQImage(image); } -void QCocoaNativeInterface::setWindowContentView(QPlatformWindow *window, void *contentView) -{ - QCocoaWindow *cocoaPlatformWindow = static_cast<QCocoaWindow *>(window); - cocoaPlatformWindow->setView(reinterpret_cast<NSView *>(contentView)); -} - void QCocoaNativeInterface::setEmbeddedInForeignView(QPlatformWindow *window, bool embedded) { QCocoaWindow *cocoaPlatformWindow = static_cast<QCocoaWindow *>(window); |