diff options
author | Armin Le Grand <Armin.Le.Grand@cib.de> | 2018-09-21 16:42:01 +0200 |
---|---|---|
committer | Armin Le Grand <Armin.Le.Grand@cib.de> | 2018-09-21 20:12:09 +0200 |
commit | 80b287ad0322afcbf8f80b0507e212870dcf0f98 (patch) | |
tree | 7710bc62dfc82d4b77d2f1de3beb55599c4e3527 /basegfx/source | |
parent | c8b2849d140677f7b35523096eb2bc715b3dc507 (diff) |
Support buffering SystemDependent GraphicData
Started to make the buffering more flexible by adding
virtual methods
virtual sal_uInt32 getHoldCyclesInSeconds() const;
virtual sal_Int64 estimateUsageInBytes() const;
to class SystemDependentData. This will allow to add more
sensitive buffering/caching.
Also fine-tuned Linux-derived classes actively used for buffering
to be more sensitive when and where to reuse the buffered data
Change-Id: Ifc69c318ade0209aff071d76001869d9f4eeb10d
Reviewed-on: https://gerrit.libreoffice.org/60881
Tested-by: Jenkins
Reviewed-by: Armin Le Grand <Armin.Le.Grand@cib.de>
Diffstat (limited to 'basegfx/source')
-rw-r--r-- | basegfx/source/tools/systemdependentdata.cxx | 18 |
1 files changed, 14 insertions, 4 deletions
diff --git a/basegfx/source/tools/systemdependentdata.cxx b/basegfx/source/tools/systemdependentdata.cxx index 45f2efba5012..4153d35f7d55 100644 --- a/basegfx/source/tools/systemdependentdata.cxx +++ b/basegfx/source/tools/systemdependentdata.cxx @@ -61,16 +61,26 @@ namespace basegfx namespace basegfx { SystemDependentData::SystemDependentData( - SystemDependentDataManager& rSystemDependentDataManager, - sal_uInt32 nHoldCycles) - : mrSystemDependentDataManager(rSystemDependentDataManager), - mnHoldCycles(nHoldCycles) + SystemDependentDataManager& rSystemDependentDataManager) + : mrSystemDependentDataManager(rSystemDependentDataManager) { } SystemDependentData::~SystemDependentData() { } + + sal_uInt32 SystemDependentData::getHoldCyclesInSeconds() const + { + // default implementation returns 60(s) + return 60; + } + + sal_Int64 SystemDependentData::estimateUsageInBytes() const + { + // default implementation has no idea + return 0; + } } // namespace basegfx namespace basegfx |