diff options
author | Tomaž Vajngerl <tomaz.vajngerl@collabora.co.uk> | 2018-04-14 15:13:05 +0900 |
---|---|---|
committer | Tomaž Vajngerl <quikee@gmail.com> | 2018-04-20 09:15:22 +0200 |
commit | 7b355669c6ddeab2e6cec692d6afdff41c61d0fb (patch) | |
tree | 46c55326bccfa68a2bb5fad6d637e0f4576c8d68 /include/vcl/gfxlink.hxx | |
parent | tdf#42949 Remove unnecessary localization headers of svtools (diff) | |
download | core-7b355669c6ddeab2e6cec692d6afdff41c61d0fb.tar.gz core-7b355669c6ddeab2e6cec692d6afdff41c61d0fb.zip |
Function to load graphic swapped out (loaded on demand)
When a document is loaded it takes a lot of time and memory to
load the graphic that are in the documet, so avoid that and just
store the compressed graphic into a temporary file (handeled by
GfxLink) and load when we really need to show the graphic.
GraphicObject cached some attributes from Graphic, but this
attributes now aren't available immediately so this attributes
are removed form GraphicObject and now delegate to the Graphic
itself. GetSizeBytes attribute however was removed as it is
only used in some tests.
GfxLink initial values were moved to the constructor and are
not set in the header file anymore (as it is the recommended
way to do it).
The SdImportTest::testDocumentLayout failed as it looks like the
dump sometimes didn't include the width and height of the null
bitmap (which is set to 32x32) of the FillBitmap in some
situations, but then in other situations it did include this
attributes. With this change the width and height are always
included for the FillBitmap which looks like it is more correct.
Change-Id: Ia1218f93b1735402b7828404f65660e2d4acf32f
Reviewed-on: https://gerrit.libreoffice.org/53016
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Diffstat (limited to 'include/vcl/gfxlink.hxx')
-rw-r--r-- | include/vcl/gfxlink.hxx | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/include/vcl/gfxlink.hxx b/include/vcl/gfxlink.hxx index 2d84fd293e4f..054ab2cf2dca 100644 --- a/include/vcl/gfxlink.hxx +++ b/include/vcl/gfxlink.hxx @@ -64,17 +64,17 @@ private: }; - GfxLinkType meType = GfxLinkType::NONE; - sal_uInt32 mnUserId = 0; + GfxLinkType meType; + sal_uInt32 mnUserId; std::shared_ptr<sal_uInt8> mpSwapInData; std::shared_ptr<SwapOutData> mpSwapOutData; - sal_uInt32 mnSwapInDataSize = 0; + sal_uInt32 mnSwapInDataSize; MapMode maPrefMapMode; Size maPrefSize; - bool mbPrefMapModeValid = false; - bool mbPrefSizeValid = false; + bool mbPrefMapModeValid; + bool mbPrefSizeValid; SAL_DLLPRIVATE std::shared_ptr<sal_uInt8> GetSwapInData() const; public: |