Simplify previous fix
...e735de2051143347b7283c85ad80b0e2412522dc "Avoid some unnecessary, wrong downcasts during `make translations" Change-Id: If6110e16698302b3d43b2192cf0f0e0d0fddb57b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/143026 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
This commit is contained in:
parent
017c38a970
commit
337691db0e
2 changed files with 4 additions and 10 deletions
|
@ -161,7 +161,7 @@ public:
|
|||
void Write( OString const &rFilename );
|
||||
void Write( std::ofstream &rStream, XMLNode *pCur = nullptr );
|
||||
|
||||
bool CheckExportStatus( XMLParentNode *pCur = nullptr );
|
||||
bool CheckExportStatus( XMLChildNode *pCur = nullptr );
|
||||
|
||||
XMLFile& operator=(const XMLFile& rObj);
|
||||
|
||||
|
|
|
@ -473,7 +473,7 @@ void XMLFile::SearchL10NElements( XMLChildNode *pCur )
|
|||
}
|
||||
}
|
||||
|
||||
bool XMLFile::CheckExportStatus( XMLParentNode *pCur )
|
||||
bool XMLFile::CheckExportStatus( XMLChildNode *pCur )
|
||||
{
|
||||
static bool bStatusExport = true;
|
||||
|
||||
|
@ -489,7 +489,7 @@ bool XMLFile::CheckExportStatus( XMLParentNode *pCur )
|
|||
for ( size_t i = 0; i < GetChildList()->size(); i++ )
|
||||
{
|
||||
XMLChildNode* pElement = (*GetChildList())[ i ];
|
||||
if( pElement->GetNodeType() == XMLNodeType::ELEMENT ) CheckExportStatus( static_cast<XMLParentNode*>(pElement) );//, i);
|
||||
if( pElement->GetNodeType() == XMLNodeType::ELEMENT ) CheckExportStatus( pElement );//, i);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -520,13 +520,7 @@ bool XMLFile::CheckExportStatus( XMLParentNode *pCur )
|
|||
else if ( pElement->GetChildList() )
|
||||
{
|
||||
for (size_t k = 0; k < pElement->GetChildList()->size(); ++k)
|
||||
{
|
||||
auto const child = (*pElement->GetChildList())[k];
|
||||
auto const type = child->GetNodeType();
|
||||
if (type != XMLNodeType::DATA && type != XMLNodeType::COMMENT) {
|
||||
CheckExportStatus( static_cast<XMLParentNode*>(child) );
|
||||
}
|
||||
}
|
||||
CheckExportStatus( (*pElement->GetChildList())[k] );
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
|
Loading…
Reference in a new issue