From f7323fcf1277268931bb336047e1186a20affcf6 Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Mon, 21 May 2012 12:38:46 +0200 Subject: [PATCH] QtDeclarative: Fix warnings about deprecated QCoreApplication::translate(). Change-Id: I4abd4ee98ca9d4267c5ad71d3b9c2e7d5de60902 Reviewed-by: Lars Knoll --- src/qml/qml/qqmlvme.cpp | 1 - src/qml/qml/v8/qqmlbuiltinfunctions.cpp | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/qml/qml/qqmlvme.cpp b/src/qml/qml/qqmlvme.cpp index 08ab494..b86e3be 100644 --- a/src/qml/qml/qqmlvme.cpp +++ b/src/qml/qml/qqmlvme.cpp @@ -402,7 +402,6 @@ QObject *QQmlVME::run(QList *errors, QCoreApplication::translate(DATAS.at(instr.context).constData(), DATAS.at(instr.text).constData(), DATAS.at(instr.comment).constData(), - QCoreApplication::UnicodeUTF8, instr.n)); QML_STORE_VALUE(StoreTrIdString, QString, qtTrId(DATAS.at(instr.text).constData(), instr.n)); diff --git a/src/qml/qml/v8/qqmlbuiltinfunctions.cpp b/src/qml/qml/v8/qqmlbuiltinfunctions.cpp index 26ecc93..dd5131f 100644 --- a/src/qml/qml/v8/qqmlbuiltinfunctions.cpp +++ b/src/qml/qml/v8/qqmlbuiltinfunctions.cpp @@ -1210,7 +1210,7 @@ v8::Handle qsTranslate(const v8::Arguments &args) QString result = QCoreApplication::translate(context.toUtf8().constData(), text.toUtf8().constData(), comment.toUtf8().constData(), - QCoreApplication::UnicodeUTF8, n); + n); return v8engine->toString(result); } @@ -1249,7 +1249,7 @@ v8::Handle qsTr(const v8::Arguments &args) n = args[2]->Int32Value(); QString result = QCoreApplication::translate(context.toUtf8().constData(), text.toUtf8().constData(), - comment.toUtf8().constData(), QCoreApplication::UnicodeUTF8, n); + comment.toUtf8().constData(), n); return v8engine->toString(result); } -- 2.7.4