diff options
author | Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> | 2015-03-04 11:27:27 +0100 |
---|---|---|
committer | Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> | 2015-03-05 10:03:30 +0000 |
commit | adaa3fc546ed831ec69a019c1e0ef48d9e69eb12 (patch) | |
tree | dd2f49b2df1a324226f395b42cb4b41f07afd38b /src/qml/parser | |
parent | 4d8b9373c62b9b58c54548f41f1e9d84e9522c6e (diff) |
Fix invocations of static methods of QGuiApplication/QCoreApplication.
Change-Id: I7bcc209b0c6e77cf6d974af85a19487345a48975
Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
Diffstat (limited to 'src/qml/parser')
-rw-r--r-- | src/qml/parser/qqmljs.g | 10 | ||||
-rw-r--r-- | src/qml/parser/qqmljsparser.cpp | 12 |
2 files changed, 11 insertions, 11 deletions
diff --git a/src/qml/parser/qqmljs.g b/src/qml/parser/qqmljs.g index ae430e942d..71b6978983 100644 --- a/src/qml/parser/qqmljs.g +++ b/src/qml/parser/qqmljs.g @@ -3055,9 +3055,9 @@ PropertyAssignmentListOpt: PropertyAssignmentList ; QString msg; int token = token_buffer[0].token; if (token < 0 || token >= TERMINAL_COUNT) - msg = qApp->translate("QQmlParser", "Syntax error"); + msg = QCoreApplication::translate("QQmlParser", "Syntax error"); else - msg = qApp->translate("QQmlParser", "Unexpected token `%1'").arg(QLatin1String(spell[token])); + msg = QCoreApplication::translate("QQmlParser", "Unexpected token `%1'").arg(QLatin1String(spell[token])); diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, token_buffer[0].loc, msg)); action = errorState; @@ -3085,7 +3085,7 @@ PropertyAssignmentListOpt: PropertyAssignmentList ; for (int *tk = tokens; *tk != EOF_SYMBOL; ++tk) { int a = t_action(errorState, *tk); if (a > 0 && t_action(a, yytoken)) { - const QString msg = qApp->translate("QQmlParser", "Expected token `%1'").arg(QLatin1String(spell[*tk])); + const QString msg = QCoreApplication::translate("QQmlParser", "Expected token `%1'").arg(QLatin1String(spell[*tk])); diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, token_buffer[0].loc, msg)); yytoken = *tk; @@ -3109,7 +3109,7 @@ PropertyAssignmentListOpt: PropertyAssignmentList ; int a = t_action(errorState, tk); if (a > 0 && t_action(a, yytoken)) { - const QString msg = qApp->translate("QQmlParser", "Expected token `%1'").arg(QLatin1String(spell[tk])); + const QString msg = QCoreApplication::translate("QQmlParser", "Expected token `%1'").arg(QLatin1String(spell[tk])); diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, token_buffer[0].loc, msg)); yytoken = tk; @@ -3122,7 +3122,7 @@ PropertyAssignmentListOpt: PropertyAssignmentList ; } } - const QString msg = qApp->translate("QQmlParser", "Syntax error"); + const QString msg = QCoreApplication::translate("QQmlParser", "Syntax error"); diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, token_buffer[0].loc, msg)); } diff --git a/src/qml/parser/qqmljsparser.cpp b/src/qml/parser/qqmljsparser.cpp index 520c377034..c1162f875c 100644 --- a/src/qml/parser/qqmljsparser.cpp +++ b/src/qml/parser/qqmljsparser.cpp @@ -1807,7 +1807,7 @@ case 355: { yylloc.startColumn += yylloc.length; yylloc.length = 0; - //const QString msg = qApp->translate("QQmlParser", "Missing `;'"); + //const QString msg = QCoreApplication::translate("QQmlParser", "Missing `;'"); //diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Warning, yylloc, msg)); first_token = &token_buffer[0]; @@ -1837,9 +1837,9 @@ case 355: { QString msg; int token = token_buffer[0].token; if (token < 0 || token >= TERMINAL_COUNT) - msg = qApp->translate("QQmlParser", "Syntax error"); + msg = QCoreApplication::translate("QQmlParser", "Syntax error"); else - msg = qApp->translate("QQmlParser", "Unexpected token `%1'").arg(QLatin1String(spell[token])); + msg = QCoreApplication::translate("QQmlParser", "Unexpected token `%1'").arg(QLatin1String(spell[token])); diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, token_buffer[0].loc, msg)); action = errorState; @@ -1867,7 +1867,7 @@ case 355: { for (int *tk = tokens; *tk != EOF_SYMBOL; ++tk) { int a = t_action(errorState, *tk); if (a > 0 && t_action(a, yytoken)) { - const QString msg = qApp->translate("QQmlParser", "Expected token `%1'").arg(QLatin1String(spell[*tk])); + const QString msg = QCoreApplication::translate("QQmlParser", "Expected token `%1'").arg(QLatin1String(spell[*tk])); diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, token_buffer[0].loc, msg)); yytoken = *tk; @@ -1891,7 +1891,7 @@ case 355: { int a = t_action(errorState, tk); if (a > 0 && t_action(a, yytoken)) { - const QString msg = qApp->translate("QQmlParser", "Expected token `%1'").arg(QLatin1String(spell[tk])); + const QString msg = QCoreApplication::translate("QQmlParser", "Expected token `%1'").arg(QLatin1String(spell[tk])); diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, token_buffer[0].loc, msg)); yytoken = tk; @@ -1904,7 +1904,7 @@ case 355: { } } - const QString msg = qApp->translate("QQmlParser", "Syntax error"); + const QString msg = QCoreApplication::translate("QQmlParser", "Syntax error"); diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, token_buffer[0].loc, msg)); } |