Cocoa: Fix qmlscene flicker on resize.
Update the GL context before sending the geometry change event to Qt. Change-Id: If331bfcc7f7b0fd4f2f24d4445c8197ec6af688f Reviewed-on: http://codereview.qt.nokia.com/3448 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@nokia.com>
This commit is contained in:
parent
38364209a9
commit
c1ccf69226
@ -179,12 +179,12 @@ void QCocoaWindow::windowDidMove()
|
|||||||
|
|
||||||
void QCocoaWindow::windowDidResize()
|
void QCocoaWindow::windowDidResize()
|
||||||
{
|
{
|
||||||
|
if (m_glContext)
|
||||||
|
m_glContext->update();
|
||||||
|
|
||||||
NSRect rect = [[m_nsWindow contentView]frame];
|
NSRect rect = [[m_nsWindow contentView]frame];
|
||||||
QRect geo(rect.origin.x,rect.origin.y,rect.size.width,rect.size.height);
|
QRect geo(rect.origin.x,rect.origin.y,rect.size.width,rect.size.height);
|
||||||
QWindowSystemInterface::handleSynchronousGeometryChange(window(), geo);
|
QWindowSystemInterface::handleSynchronousGeometryChange(window(), geo);
|
||||||
|
|
||||||
if (m_glContext)
|
|
||||||
m_glContext->update();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user