diff options
author | Zolnai Tamás <zolnaitamas2000@gmail.com> | 2012-12-13 15:32:02 +0100 |
---|---|---|
committer | Zolnai Tamás <zolnaitamas2000@gmail.com> | 2012-12-13 16:29:34 +0100 |
commit | 3ddd4502c4d4e234017e01ead26813caf81593e8 (patch) | |
tree | d24b214adb6b0a8519b76e7757b5c9ba75a30181 | |
parent | caa03b3c9b979cde94896952ab909d302444b9c0 (diff) |
Fix adding keyid to po when read from file
Change-Id: I29fdd23da97f1102974a6b5821c224264a37efc3
-rw-r--r-- | l10ntools/source/po.cxx | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/l10ntools/source/po.cxx b/l10ntools/source/po.cxx index 8d51671e1d5b..cdc2c9847ebb 100644 --- a/l10ntools/source/po.cxx +++ b/l10ntools/source/po.cxx @@ -793,14 +793,7 @@ void PoIfstream::readEntry( PoEntry& rPoEntry ) (sType == "text" || sType == "quickhelptext" || sType == "title")&& !aGenPo.getMsgId().isEmpty() ) { - if( rPoEntry.m_pGenPo ) - { - *(rPoEntry.m_pGenPo) = aGenPo; - } - else - { - rPoEntry.m_pGenPo = new GenPoEntry( aGenPo ); - } + //Generate keyid if po file not includes it const OString sExtractCom = aGenPo.getExtractCom(); if( sExtractCom.isEmpty() || ( sExtractCom.getLength() != 4 && @@ -812,6 +805,14 @@ void PoIfstream::readEntry( PoEntry& rPoEntry ) aGenPo.getReference() + sMsgCtxt + aGenPo.getMsgId() ) ); } + if( rPoEntry.m_pGenPo ) + { + *(rPoEntry.m_pGenPo) = aGenPo; + } + else + { + rPoEntry.m_pGenPo = new GenPoEntry( aGenPo ); + } rPoEntry.m_bIsInitialized = true; } else |