diff options
author | jan iversen <jani@documentfoundation.org> | 2016-04-04 19:37:01 +0200 |
---|---|---|
committer | jan iversen <jani@documentfoundation.org> | 2016-04-04 19:37:01 +0200 |
commit | 2ef9d5de7df7b38e091af7bd7276e68812493cc0 (patch) | |
tree | 2e87eee8dde58034985a96ff2004fed934ec8e01 /l10ntools/source/gConvPo.cxx | |
parent | 3ada44f631490f8910ce0bcf55353f70d7d0df6d (diff) |
genlang, update to satisfy clang.
changes due a log from clang tinderbox.
minor changes to interpret more files
Change-Id: I3821aab91dc21e74c870628a4f2265ab61d37cca
Diffstat (limited to 'l10ntools/source/gConvPo.cxx')
-rw-r--r-- | l10ntools/source/gConvPo.cxx | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/l10ntools/source/gConvPo.cxx b/l10ntools/source/gConvPo.cxx index 1483d099aae4..29cb2fe4acfc 100644 --- a/l10ntools/source/gConvPo.cxx +++ b/l10ntools/source/gConvPo.cxx @@ -67,7 +67,7 @@ void convert_po::startLook() // load in db if (msId.size()) - mcMemory.loadEntryKey(miLineNo, sFileName, sNewKey, msId, msStr, "", "", mbFuzzy); + mcMemory.loadEntryKey(miLineNo, sFileName, sNewKey, msId, msStr, "", "", "", mbFuzzy); // and prepare for new entry msKey.clear(); @@ -178,9 +178,9 @@ void convert_po::startSave(const string& sName, << "msgstr \"\"" << endl << "\"Project-Id-Version: PACKAGE VERSION\\n\"" << endl << "\"Report-Msgid-Bugs-To: " - << "https://bugs.libreoffice.org/enter_bug.cgi?" - << "product=LibreOffice&bug_status=UNCONFIRMED" - << "&component=UI\\n\"" << endl + "https://bugs.libreoffice.org/enter_bug.cgi?" + "product=LibreOffice&bug_status=UNCONFIRMED" + "&component=UI\\n\"" << endl << "\"POT-Creation-Date: " << std::put_time(&tm, "%Y-%m-%d %H:%M%z") << "\\n\"" << endl << "\"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\\n\"" << endl @@ -201,6 +201,7 @@ void convert_po::save(const string& sFileName, const string& sText, const string& sComment, const string& sResource, + const string& sGroup, bool bFuzzy) { string sName; @@ -211,14 +212,16 @@ void convert_po::save(const string& sFileName, newPos = sFileName.find_last_of("/\\", sFileName.length()); sName = sFileName.substr(newPos + 1, sFileName.length()); - outFile << endl << "#. " << genKeyId(sName + sKey + sResource + sENUStext) << endl; + outFile << endl << "#. " << genKeyId(sName + sKey + sGroup + sResource + sENUStext) << endl; if (sComment.length()) outFile << "#. " << sComment << endl; outFile << "#: " << sName << endl << "msgctxt \"\"" << endl << "\"" << sName << "\\n\"" << endl - << "\"" << sKey << "\\n\"" << endl - << "\"" << sResource << ".text\"" << endl; + << "\"" << sKey << "\\n\"" << endl; + if (sGroup.length()) + outFile << "\"" << sGroup << "\\n\"" << endl; + outFile << "\"" << sResource << ".text\"" << endl; if (bFuzzy) outFile << "#, fuzzy" << endl; outFile << "msgid \"" << sENUStext << "\"" << endl |