diff options
author | Tomaž Vajngerl <tomaz.vajngerl@collabora.co.uk> | 2020-09-23 23:28:30 +0200 |
---|---|---|
committer | Andras Timar <andras.timar@collabora.com> | 2020-10-06 08:24:46 +0200 |
commit | d483df8fee614261170f7b7b6ad8a3e155727a21 (patch) | |
tree | fc4f4470f19c15816c26d9d1b0f60045c12b2772 /accessibility | |
parent | 8c75dc8cdae09aeae447862cdfc1fda948bc369d (diff) |
fix Graphic duplication in import and add GraphicMapper
When importing writerfilter, we change to oox when
importing images. This transition doesn't store any
previous contexts and all instances are reset. The
problem occurs when we have identical images because
the transition erases all caches we have to determine
if an image has already been imported or not, which
causes that we import the same image multiple times
which create unnecessary copies.
This introduces the XGraphicMapper, which can be used
to store the XGraphic for a key and can be transferred
between writerfilter to oox. With this we can remember
which images were already imported and don't create
unnecessary internal copies which decreases memory.
This also includes a test which checks that the import
and export doesn't produce unnecessary copies of
identical images. The test checks that for OOXML, ODF
and MS Binary formats.
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103283
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
(cherry picked from commit d0efd878dc41e3913a2d91ff4b5c335c1d71a85c)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103407
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
(cherry picked from commit 3de1b009bd187afa1dd49b10644c1920641e1596)
Change-Id: I33dc19218c565937fab77e132b3a996c51358b6e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103607
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Diffstat (limited to 'accessibility')
0 files changed, 0 insertions, 0 deletions