summaryrefslogtreecommitdiff
path: root/l10ntools/source/gConvXhp.cxx
diff options
context:
space:
mode:
authorjan iversen <jani@documentfoundation.org>2016-03-20 23:52:53 +0100
committerjan iversen <jani@documentfoundation.org>2016-03-22 16:32:19 +0100
commit3ec0b7ed0d2028517afaee5c3ffa0b9f04a68bd2 (patch)
tree666058a194391072d21ae3f7c215ddaf7060efe2 /l10ntools/source/gConvXhp.cxx
parentaad4aa640f691dab012b5b63f3d7f242f18a1c21 (diff)
genlang .xhp ==> .pot identical
Checked .xhp conversion. The current tools have a problem with windows get an error "cannot convert path to URL", seems it was not tested on windows. Also "make translations" does not cover submodules. Change-Id: I36a0a3643eb40ff9c02735acdf79498d16691069
Diffstat (limited to 'l10ntools/source/gConvXhp.cxx')
-rw-r--r--l10ntools/source/gConvXhp.cxx10
1 files changed, 8 insertions, 2 deletions
diff --git a/l10ntools/source/gConvXhp.cxx b/l10ntools/source/gConvXhp.cxx
index 0a08ec7080f0..f12422c1ed3d 100644
--- a/l10ntools/source/gConvXhp.cxx
+++ b/l10ntools/source/gConvXhp.cxx
@@ -54,6 +54,8 @@ void convert_xhp::doExecute()
string sLang;
string sFile, sFile2;
+ mcMemory.setResourceName("help");
+
// prepare list with languages
miCntLanguages = mcMemory.prepareMerge();
if (mbMergeMode) {
@@ -245,8 +247,12 @@ void convert_xhp::closeTransTag(char *yytext)
if (meExpectValue == VALUE_IS_VALUE || meExpectValue == VALUE_IS_VALUE_TAG) {
- if (msCollector.size() && msCollector != "-")
- mcMemory.setSourceKey(miLineNo, msSourceFile, msKey, msCollector, mbMergeMode);
+ if (msCollector.size() && msCollector != "-") {
+ string newString(msCollector);
+ if (newString[newString.length() - 1] == ' ')
+ newString = newString.substr(0, newString.length() - 1);
+ mcMemory.setSourceKey(miLineNo, msSourceFile, msKey, newString, mbMergeMode);
+ }
msKey.clear();
iType = 2;
}