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>
This commit is contained in:
Marc Mutz 2012-06-29 11:09:11 +02:00 committed by Qt by Nokia
parent 551e1e63d9
commit e6c98287cc

View File

@ -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);
}