Implement map/unmap and force geometry EglFS
Change-Id: Ia2d86e84acfeb30f41b06f106b93033fe54ed839 Reviewed-on: http://codereview.qt.nokia.com/2730 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
This commit is contained in:
parent
e09d427baf
commit
5c435189d4
@ -51,8 +51,13 @@ QEglFSWindow::QEglFSWindow(QWindow *w)
|
|||||||
static int serialNo = 0;
|
static int serialNo = 0;
|
||||||
m_winid = ++serialNo;
|
m_winid = ++serialNo;
|
||||||
#ifdef QEGL_EXTRA_DEBUG
|
#ifdef QEGL_EXTRA_DEBUG
|
||||||
qWarning("QEglWindow %p: %p %p 0x%x\n", this, w, screen, uint(m_winid));
|
qWarning("QEglWindow %p: %p 0x%x\n", this, w, uint(m_winid));
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
QRect screenGeometry(screen()->availableGeometry());
|
||||||
|
if (w->geometry() != screenGeometry) {
|
||||||
|
QWindowSystemInterface::handleGeometryChange(w, screenGeometry);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void QEglFSWindow::setGeometry(const QRect &)
|
void QEglFSWindow::setGeometry(const QRect &)
|
||||||
@ -69,4 +74,14 @@ WId QEglFSWindow::winId() const
|
|||||||
return m_winid;
|
return m_winid;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void QEglFSWindow::setVisible(bool visible)
|
||||||
|
{
|
||||||
|
if (visible) {
|
||||||
|
QWindowSystemInterface::handleMapEvent(window());
|
||||||
|
} else {
|
||||||
|
QWindowSystemInterface::handleUnmapEvent(window());
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
QT_END_NAMESPACE
|
QT_END_NAMESPACE
|
||||||
|
@ -58,6 +58,8 @@ public:
|
|||||||
void setGeometry(const QRect &);
|
void setGeometry(const QRect &);
|
||||||
WId winId() const;
|
WId winId() const;
|
||||||
|
|
||||||
|
void setVisible(bool visible);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
WId m_winid;
|
WId m_winid;
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user