diff options
Diffstat (limited to 'l10ntools/source/po.cxx')
-rw-r--r-- | l10ntools/source/po.cxx | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/l10ntools/source/po.cxx b/l10ntools/source/po.cxx index 2ccaed61bb17..df9efe31bc64 100644 --- a/l10ntools/source/po.cxx +++ b/l10ntools/source/po.cxx @@ -452,8 +452,7 @@ PoEntry::PoEntry(const OString& rSDFLine, const TYPE eType) copy(vParts[SOURCEFILE].lastIndexOf("\\")+1)); OString sMsgCtxt = - vParts[SOURCEFILE].copy(vParts[SOURCEFILE].lastIndexOf("\\")+1) + - "\n" + vParts[GROUPID] + "\n" + + vParts[GROUPID] + "\n" + (vParts[LOCALID].isEmpty() ? "" : vParts[LOCALID] + "\n") + vParts[RESOURCETYPE]; switch(eType){ @@ -528,7 +527,7 @@ OString PoEntry::getSourceFile() const OString PoEntry::getGroupId() const { assert( m_bIsInitialized ); - return m_pGenPo->getMsgCtxt().getToken(1,'\n'); + return m_pGenPo->getMsgCtxt().getToken(0,'\n'); } //Get localid @@ -539,7 +538,7 @@ OString PoEntry::getLocalId() const if (sMsgCtxt.indexOf('\n')==sMsgCtxt.lastIndexOf('\n')) return OString(); else - return sMsgCtxt.getToken(2,'\n'); + return sMsgCtxt.getToken(1,'\n'); } //Get the type of component from which entry is extracted @@ -548,9 +547,9 @@ OString PoEntry::getResourceType() const assert( m_bIsInitialized ); const OString sMsgCtxt = m_pGenPo->getMsgCtxt(); if (sMsgCtxt.indexOf('\n')==sMsgCtxt.lastIndexOf('\n')) - return sMsgCtxt.getToken(2,'\n').getToken(0,'.'); + return sMsgCtxt.getToken(1,'\n').getToken(0,'.'); else - return sMsgCtxt.getToken(3,'\n').getToken(0,'.'); + return sMsgCtxt.getToken(2,'\n').getToken(0,'.'); } //Get the type of entry |