diff options
author | David Boddie <dboddie@trolltech.com> | 2009-07-07 13:00:14 (GMT) |
---|---|---|
committer | David Boddie <dboddie@trolltech.com> | 2009-07-07 13:00:14 (GMT) |
commit | f5392a4290e5f7ae2bdf268c1fa8c037e776fdae (patch) | |
tree | d3cc657639b8784dbc22eae2bae5e58e62db7a2f /tools/linguist/shared/po.cpp | |
parent | 0044b3c968f5023f502e3574c96d4e4df0de865d (diff) | |
parent | 2a834d39a69430058df3916392afab064ca941ee (diff) | |
download | Qt-f5392a4290e5f7ae2bdf268c1fa8c037e776fdae.zip Qt-f5392a4290e5f7ae2bdf268c1fa8c037e776fdae.tar.gz Qt-f5392a4290e5f7ae2bdf268c1fa8c037e776fdae.tar.bz2 |
Merge branch 'master' of git@scm.dev.nokia.troll.no:qt/qt
Conflicts:
src/network/socket/qlocalsocket.cpp
Diffstat (limited to 'tools/linguist/shared/po.cpp')
-rw-r--r-- | tools/linguist/shared/po.cpp | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/tools/linguist/shared/po.cpp b/tools/linguist/shared/po.cpp index cb943be..e22aa7d 100644 --- a/tools/linguist/shared/po.cpp +++ b/tools/linguist/shared/po.cpp @@ -395,7 +395,10 @@ bool loadPO(Translator &translator, QIODevice &dev, ConversionData &cd) const QString prefix = QLatin1String(isObsolete ? "#~ " : ""); while (true) { int idx = line.indexOf(QLatin1Char(' '), prefix.length()); - item.msgStr.append(slurpEscapedString(lines, l, idx, prefix, cd)); + QString str = slurpEscapedString(lines, l, idx, prefix, cd); + str.replace(QChar(Translator::TextVariantSeparator), + QChar(Translator::BinaryVariantSeparator)); + item.msgStr.append(str); if (l + 1 >= lines.size() || !isTranslationLine(lines.at(l + 1))) break; ++l; @@ -635,8 +638,11 @@ bool savePO(const Translator &translator, QIODevice &dev, ConversionData &cd) out << poEscapedString(prefix, QLatin1String("msgid_plural"), noWrap, plural); QStringList translations = translator.normalizedTranslations(msg, cd, &ok); for (int i = 0; i != translations.size(); ++i) { + QString str = translations.at(i); + str.replace(QChar(Translator::BinaryVariantSeparator), + QChar(Translator::TextVariantSeparator)); out << poEscapedString(prefix, QString::fromLatin1("msgstr[%1]").arg(i), noWrap, - translations.at(i)); + str); } } first = false; |