eglfs: Make sure virtual functions are not called from ctor

We want to override some of them in a subclass.

Change-Id: Ic7a22d7bc4589199b3f764157125094a4ff6ec28
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
bb10
Eskil Abrahamsen Blomfeldt 2013-04-12 15:08:02 +02:00 committed by The Qt Project
parent 6e0f55495d
commit aec1bcf6a3
2 changed files with 4 additions and 5 deletions

View File

@ -145,7 +145,8 @@ bool QEglFSIntegration::hasCapability(QPlatformIntegration::Capability cap) cons
QPlatformWindow *QEglFSIntegration::createPlatformWindow(QWindow *window) const
{
QPlatformWindow *w = new QEglFSWindow(window);
QEglFSWindow *w = new QEglFSWindow(window);
w->create();
w->requestActivateWindow();
return w;
}

View File

@ -59,10 +59,6 @@ QEglFSWindow::QEglFSWindow(QWindow *w)
#ifdef QEGL_EXTRA_DEBUG
qWarning("QEglWindow %p: %p 0x%x\n", this, w, uint(m_winid));
#endif
setWindowState(Qt::WindowFullScreen);
create();
}
QEglFSWindow::~QEglFSWindow()
@ -72,6 +68,8 @@ QEglFSWindow::~QEglFSWindow()
void QEglFSWindow::create()
{
setWindowState(Qt::WindowFullScreen);
if (m_window)
return;