sw/source/filter/docx/swdocxreader.cxx | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-)
New commits: commit 0b2d434106c50785b1c0317d49368c0dc6d084b0 Author: Miklos Vajna <vmik...@collabora.com> AuthorDate: Thu Mar 14 15:51:07 2019 +0100 Commit: Andras Timar <andras.ti...@collabora.com> CommitDate: Mon Mar 18 09:59:57 2019 +0100 DOCX autotext import: speed up handling of large amount of blocks WW8Glossary::Load() does the same for the DOC autotext import. Old cost for a document with 2508 document parts: 843842 ms. New cost for the same document: 46572 ms (5% of baseline). (cherry picked from commit 87670fa998a26ab059e40bbe8f5e0acf0ad6ea04) Change-Id: If0ff183315cb7465dd2b32c1a4fc856b50611265 Reviewed-on: https://gerrit.libreoffice.org/69381 Reviewed-by: Andras Timar <andras.ti...@collabora.com> Tested-by: Andras Timar <andras.ti...@collabora.com> diff --git a/sw/source/filter/docx/swdocxreader.cxx b/sw/source/filter/docx/swdocxreader.cxx index 4386de8fdc3e..1924e13dbf86 100644 --- a/sw/source/filter/docx/swdocxreader.cxx +++ b/sw/source/filter/docx/swdocxreader.cxx @@ -127,7 +127,14 @@ bool SwDOCXReader::ReadGlossaries( SwTextBlocks& rBlocks, bool /* bSaveRelFiles })); if( xFilter->filter( aDescriptor ) ) - return MakeEntries( static_cast<SwDocShell*>( &xDocSh )->GetDoc(), rBlocks ); + { + if (rBlocks.StartPutMuchBlockEntries()) + { + bool bRet = MakeEntries(static_cast<SwDocShell*>(&xDocSh)->GetDoc(), rBlocks); + rBlocks.EndPutMuchBlockEntries(); + return bRet; + } + } } return false; _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits