diff options
author | Morten Johan Sørvig <morten.sorvig@digia.com> | 2013-01-07 22:38:10 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-02-12 07:50:03 +0100 |
commit | 784b9655597d2c23a00d57181b1853e6df07fdf3 (patch) | |
tree | 5b0faeeae6c12abeb0a83ec1910bef26172da88b /src/plugins/platforms/cocoa/qcocoanativeinterface.h | |
parent | 00d8de8589fc799015af1aa9a84e268fba4d6a74 (diff) |
Cocoa: Export QImage <-> CGImage conversion funcs.
For implementing to/fromMacCGImageRef in QtMacExtras.
These do not depend on internal Qt state. The main
reason for exporting them is to keep the implementation
in one place to ease maintenance.
Refactor qt_mac_cg_context to support QImage.
Add qt_mac_toQImage.
Change-Id: Ia9c226ed52d087b2c6b47aa8210ed8f2645b9cf2
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
Diffstat (limited to 'src/plugins/platforms/cocoa/qcocoanativeinterface.h')
-rw-r--r-- | src/plugins/platforms/cocoa/qcocoanativeinterface.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/plugins/platforms/cocoa/qcocoanativeinterface.h b/src/plugins/platforms/cocoa/qcocoanativeinterface.h index 592ede4617..9506f86238 100644 --- a/src/plugins/platforms/cocoa/qcocoanativeinterface.h +++ b/src/plugins/platforms/cocoa/qcocoanativeinterface.h @@ -42,6 +42,8 @@ #ifndef QCOCOANATIVEINTERFACE_H #define QCOCOANATIVEINTERFACE_H +#include <ApplicationServices/ApplicationServices.h> + #include <qpa/qplatformnativeinterface.h> QT_BEGIN_NAMESPACE @@ -96,6 +98,10 @@ private: // Dock menu support static void setDockMenu(QPlatformMenu *platformMenu); + + // QImage <-> CGImage conversion functions + static CGImageRef qImageToCGImage(const QImage &image); + static QImage cgImageToQImage(CGImageRef image); }; #endif // QCOCOANATIVEINTERFACE_H |