diff options
author | Qt Continuous Integration System <qt-info@nokia.com> | 2010-08-23 12:07:25 (GMT) |
---|---|---|
committer | Qt Continuous Integration System <qt-info@nokia.com> | 2010-08-23 12:07:25 (GMT) |
commit | 168ae6571dc93ee11fc0f61db643fb7679bb729f (patch) | |
tree | def9358b6d43c16745ffe5102eb72b78cf665c92 /src | |
parent | fa11bd40388e437e4f29aab93f1c368d428e28e3 (diff) | |
parent | 1d13522190346b20bf079ae48ce919c9e15a2c7a (diff) | |
download | Qt-168ae6571dc93ee11fc0f61db643fb7679bb729f.zip Qt-168ae6571dc93ee11fc0f61db643fb7679bb729f.tar.gz Qt-168ae6571dc93ee11fc0f61db643fb7679bb729f.tar.bz2 |
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/qt-s60-public into 4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/qt-s60-public:
On Symbian QGLWidget::glDraw() must do nothing if widget isn't visible.
QWidget metadata has not been set up yet in QWidgetPrivate::init.
Diffstat (limited to 'src')
-rw-r--r-- | src/gui/kernel/qwidget.cpp | 4 | ||||
-rw-r--r-- | src/opengl/qgl.cpp | 5 |
2 files changed, 7 insertions, 2 deletions
diff --git a/src/gui/kernel/qwidget.cpp b/src/gui/kernel/qwidget.cpp index 8b8641f..3d2bfe2 100644 --- a/src/gui/kernel/qwidget.cpp +++ b/src/gui/kernel/qwidget.cpp @@ -1275,9 +1275,9 @@ void QWidgetPrivate::init(QWidget *parentWidget, Qt::WindowFlags f) //give potential windows a bigger "pre-initial" size; create_sys() will give them a new size later #ifdef Q_OS_SYMBIAN - if(q->inherits("QGLWidget")) { + if (isGLWidget) { // Don't waste GPU mem for unnecessary large egl surface - data.crect = parentWidget ? QRect(0,0,2,2) : QRect(0,0,2,2); + data.crect = QRect(0,0,2,2); } else { data.crect = parentWidget ? QRect(0,0,100,30) : QRect(0,0,360,640); } diff --git a/src/opengl/qgl.cpp b/src/opengl/qgl.cpp index 51187cf..9e69816 100644 --- a/src/opengl/qgl.cpp +++ b/src/opengl/qgl.cpp @@ -4445,6 +4445,11 @@ void QGLWidget::glDraw() Q_D(QGLWidget); if (!isValid()) return; +#ifdef Q_OS_SYMBIAN + // Crashes on Symbian if trying to render to invisible surfaces + if (!isVisible() && d->glcx->device()->devType() == QInternal::Widget) + return; +#endif makeCurrent(); #ifndef QT_OPENGL_ES if (d->glcx->deviceIsPixmap()) |