diff options
-rw-r--r-- | src/qml/qml/qqmlengine.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/qml/qml/qqmlengine.cpp b/src/qml/qml/qqmlengine.cpp index eb2fbcdd73..194c58b805 100644 --- a/src/qml/qml/qqmlengine.cpp +++ b/src/qml/qml/qqmlengine.cpp @@ -1342,8 +1342,11 @@ void QQmlEngine::setOutputWarningsToStandardError(bool enabled) void QQmlEngine::retranslate() { Q_D(QQmlEngine); - if (QQmlContextData *firstChildContext = QQmlContextData::get(d->rootContext)->childContexts) - firstChildContext->refreshExpressions(); + QQmlContextData *context = QQmlContextData::get(d->rootContext)->childContexts; + while (context) { + context->refreshExpressions(); + context = context->nextChild; + } } /*! |