summaryrefslogtreecommitdiffstats
path: root/src/plugins
diff options
context:
space:
mode:
authorMarc Mutz <marc.mutz.qnx@kdab.com>2012-06-29 11:09:11 +0200
committerQt by Nokia <qt-info@nokia.com>2012-06-29 15:42:05 +0200
commite6c98287cc0d05ea0d8370f1537ccc5171537091 (patch)
treea1a1dced4ae9404765e4391e5e54b9629371b48c /src/plugins
parent551e1e63d9da18787ae72fc3f0e76f28dbe5f7e3 (diff)
QQnxWindow: properly scope a local variable
Change-Id: I71f1052f614f4e926acf2c2b76963770f7b35c96 Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com> Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/platforms/qnx/qqnxwindow.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/plugins/platforms/qnx/qqnxwindow.cpp b/src/plugins/platforms/qnx/qqnxwindow.cpp
index 3344a87f12..1dfb45d7ff 100644
--- a/src/plugins/platforms/qnx/qqnxwindow.cpp
+++ b/src/plugins/platforms/qnx/qqnxwindow.cpp
@@ -214,11 +214,8 @@ void QQnxWindow::setGeometry(const QRect &rect)
QWindowSystemInterface::handleSynchronousGeometryChange(window(), rect);
// Now move all children.
- QPoint offset;
if (!oldGeometry.isEmpty()) {
- offset = rect.topLeft();
- offset -= oldGeometry.topLeft();
-
+ const QPoint offset = rect.topLeft() - oldGeometry.topLeft();
Q_FOREACH (QQnxWindow *childWindow, m_childWindows)
childWindow->setOffset(offset);
}