Commit e3ad8d7f authored by Sergey Belyashov's avatar Sergey Belyashov
Browse files

Fix JsonWizard translation



Fix generation of jsonwizard_tr.h helper file used by lupdate for
translation files.

Change-Id: I4bd293b2b107d4b7a6a49d955d9d8734a4b42e85
Reviewed-by: default avatarOswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
parent d498795c
......@@ -13,8 +13,9 @@ defineReplace(findToTranslate) {
SUBKEY = $${ROOTKEY}.$${KEY}
MATCHED = $$find(KEY, ^tr[A-Z])
!isEmpty(MATCHED) {
VALUE = $$eval($${SUBKEY})
OUTPUT += "QCoreApplication(\"ProjectExplorer::JsonWizard\", \"$${VALUE}\");"
VALUE = $$replace($${SUBKEY}, "\\n", "\\n")
VALUE ~= s,\",\\\",
OUTPUT += "QT_TRANSLATE_NOOP(\"ProjectExplorer::JsonWizard\", \"$${VALUE}\");"
}
OUTPUT += $$findToTranslate($${SUBKEY})
}
......@@ -22,8 +23,7 @@ defineReplace(findToTranslate) {
}
WIZ_TRANS_FILE_CONT= \
"// This file is autogenerated by qmake." \
"$${LITERAL_HASH}include <QCoreApplication>"
"// This file is autogenerated by qmake."
for (FILE, JSONWIZARD_FILES) {
exists($$FILE) {
......
......@@ -79,7 +79,7 @@ for(file, files) {
$$v = extract
QMAKE_EXTRA_TARGETS += ts-$$lang
}
ts-all.commands = cd $$wd && $$LUPDATE $$sources $$MIME_TR_H $$CUSTOMWIZARD_TR_H $$QMLWIZARD_TR_H $$QTQUICKWIZARD_TR_H $$EXTERNALTOOLS_TR_H -ts $$files
ts-all.commands = cd $$wd && $$LUPDATE $$sources $$MIME_TR_H $$CUSTOMWIZARD_TR_H $$JSONWIZARD_TR_H $$QMLWIZARD_TR_H $$QTQUICKWIZARD_TR_H $$EXTERNALTOOLS_TR_H -ts $$files
ts-all.depends = extract
QMAKE_EXTRA_TARGETS += ts-all
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment