summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms
diff options
context:
space:
mode:
authorGunnar Sletta <gunnar.sletta@nokia.com>2011-08-08 09:23:19 +0200
committerJørgen Lind <jorgen.lind@nokia.com>2011-08-08 09:28:01 +0200
commit5c435189d4faa5125ead13518784360a0f74b90f (patch)
treeff72e6fdd93dbcac7812f931c8f1842454220809 /src/plugins/platforms
parente09d427bafb544632382c2c3b06f1247ab6750a9 (diff)
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>
Diffstat (limited to 'src/plugins/platforms')
-rw-r--r--src/plugins/platforms/eglfs/qeglfswindow.cpp17
-rw-r--r--src/plugins/platforms/eglfs/qeglfswindow.h2
2 files changed, 18 insertions, 1 deletions
diff --git a/src/plugins/platforms/eglfs/qeglfswindow.cpp b/src/plugins/platforms/eglfs/qeglfswindow.cpp
index 25da588519..298592bae3 100644
--- a/src/plugins/platforms/eglfs/qeglfswindow.cpp
+++ b/src/plugins/platforms/eglfs/qeglfswindow.cpp
@@ -51,8 +51,13 @@ QEglFSWindow::QEglFSWindow(QWindow *w)
static int serialNo = 0;
m_winid = ++serialNo;
#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
+
+ QRect screenGeometry(screen()->availableGeometry());
+ if (w->geometry() != screenGeometry) {
+ QWindowSystemInterface::handleGeometryChange(w, screenGeometry);
+ }
}
void QEglFSWindow::setGeometry(const QRect &)
@@ -69,4 +74,14 @@ WId QEglFSWindow::winId() const
return m_winid;
}
+void QEglFSWindow::setVisible(bool visible)
+{
+ if (visible) {
+ QWindowSystemInterface::handleMapEvent(window());
+ } else {
+ QWindowSystemInterface::handleUnmapEvent(window());
+ }
+
+}
+
QT_END_NAMESPACE
diff --git a/src/plugins/platforms/eglfs/qeglfswindow.h b/src/plugins/platforms/eglfs/qeglfswindow.h
index 09f553d3b7..32a6e71683 100644
--- a/src/plugins/platforms/eglfs/qeglfswindow.h
+++ b/src/plugins/platforms/eglfs/qeglfswindow.h
@@ -58,6 +58,8 @@ public:
void setGeometry(const QRect &);
WId winId() const;
+ void setVisible(bool visible);
+
private:
WId m_winid;
};