iOS: Create QIOSBackingStore paint device lazily in paintDevice()
Instead of constructor. Change-Id: I98cddd3f39add3e6f787c858b4d629325cc0f852 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>bb10
parent
a1c9f56552
commit
8dde67fcd3
|
|
@ -69,12 +69,13 @@ void QIOSBackingStore::beginPaint(const QRegion &)
|
|||
window()->setSurfaceType(QSurface::OpenGLSurface);
|
||||
|
||||
m_context->makeCurrent(window());
|
||||
if (!m_device)
|
||||
m_device = new QOpenGLPaintDevice(window()->size());
|
||||
}
|
||||
|
||||
QPaintDevice *QIOSBackingStore::paintDevice()
|
||||
{
|
||||
if (!m_device)
|
||||
m_device = new QOpenGLPaintDevice(window()->size());
|
||||
|
||||
return m_device;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue