diff options
author | Morten Sorvig <morten.sorvig@nokia.com> | 2011-08-30 10:41:54 +0200 |
---|---|---|
committer | Samuel Rødal <samuel.rodal@nokia.com> | 2011-08-30 12:12:45 +0200 |
commit | d610fbc13e589b36ce8f1e1af7166d215f0ccc90 (patch) | |
tree | a80f8345f7c155a5d875ab008c5966c77df0cabe /src/plugins/platforms/cocoa/qcocoabackingstore.mm | |
parent | 42f2da5e6b543e698fc4f036c45ebb15078409c8 (diff) |
Cocoa: Make the hellowindow opengl example work.
You're not supposed to use NSOpenGLView and
NSOpenGLContext at the same time - it's one or
the other. Qmlscene worked because it was hitting
the raster path that doesn't have a NSOpenGLView.
Remove the NSOpenGLView path and m_windowSurfaceView.
Change-Id: I10358851a94cd1780a312af09bbb7cf5db8f984f
Reviewed-on: http://codereview.qt.nokia.com/3862
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
Diffstat (limited to 'src/plugins/platforms/cocoa/qcocoabackingstore.mm')
-rw-r--r-- | src/plugins/platforms/cocoa/qcocoabackingstore.mm | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins/platforms/cocoa/qcocoabackingstore.mm b/src/plugins/platforms/cocoa/qcocoabackingstore.mm index 1a25608a7a..5a59fb5c49 100644 --- a/src/plugins/platforms/cocoa/qcocoabackingstore.mm +++ b/src/plugins/platforms/cocoa/qcocoabackingstore.mm @@ -84,7 +84,7 @@ void QCocoaBackingStore::flush(QWindow *widget, const QRegion ®ion, const QPo QRect geo = region.boundingRect(); NSRect rect = NSMakeRect(geo.x(), geo.y(), geo.width(), geo.height()); - [m_cocoaWindow->m_windowSurfaceView displayRect:rect]; + [m_cocoaWindow->m_contentView displayRect:rect]; } void QCocoaBackingStore::resize(const QSize &size, const QRegion &) @@ -92,7 +92,7 @@ void QCocoaBackingStore::resize(const QSize &size, const QRegion &) delete m_image; m_image = new QImage(size,QImage::Format_ARGB32_Premultiplied); NSSize newSize = NSMakeSize(size.width(),size.height()); - [static_cast<QNSView *>(m_cocoaWindow->m_windowSurfaceView) setImage:m_image]; + [static_cast<QNSView *>(m_cocoaWindow->m_contentView) setImage:m_image]; } QT_END_NAMESPACE |