summaryrefslogtreecommitdiffstats
path: root/svtools
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2012-01-26 20:56:06 +0100
committerStephan Bergmann <sbergman@redhat.com>2012-01-26 20:56:44 +0100
commitd3e30409530a94470a3c19612663b26a9eafa683 (patch)
tree952a846aa33686237ca5d3cfd4779cebd4c9a20d /svtools
parentremember that map has been initialized (diff)
downloadcore-d3e30409530a94470a3c19612663b26a9eafa683.tar.gz
core-d3e30409530a94470a3c19612663b26a9eafa683.zip
Replace SvtCacheOptions with (simplified) direct configuration access.
Diffstat (limited to 'svtools')
-rw-r--r--svtools/source/graphic/grfmgr.cxx17
1 files changed, 11 insertions, 6 deletions
diff --git a/svtools/source/graphic/grfmgr.cxx b/svtools/source/graphic/grfmgr.cxx
index 2c4997532451..8098e77179e5 100644
--- a/svtools/source/graphic/grfmgr.cxx
+++ b/svtools/source/graphic/grfmgr.cxx
@@ -26,9 +26,12 @@
*
************************************************************************/
+#include "sal/config.h"
#include <algorithm>
+#include <comphelper/processfactory.hxx>
+#include <officecfg/Office/Common.hxx>
#include <tools/vcompat.hxx>
#include <unotools/ucbstreamhelper.hxx>
#include <unotools/localfilehelper.hxx>
@@ -38,7 +41,6 @@
#include <vcl/metaact.hxx>
#include <vcl/virdev.hxx>
#include <vcl/salbtype.hxx>
-#include <unotools/cacheoptions.hxx>
#include <svtools/grfmgr.hxx>
#include <vcl/pdfextoutdevdata.hxx>
@@ -176,11 +178,14 @@ void GraphicObject::ImplSetGraphicManager( const GraphicManager* pMgr, const rtl
{
if( !mpGlobalMgr )
{
- SvtCacheOptions aCacheOptions;
-
- mpGlobalMgr = new GraphicManager( aCacheOptions.GetGraphicManagerTotalCacheSize(),
- aCacheOptions.GetGraphicManagerObjectCacheSize() );
- mpGlobalMgr->SetCacheTimeout( aCacheOptions.GetGraphicManagerObjectReleaseTime() );
+ mpGlobalMgr = new GraphicManager(
+ officecfg::Office::Common::Cache::GraphicManager::TotalCacheSize::get(
+ comphelper::getProcessComponentContext()),
+ officecfg::Office::Common::Cache::GraphicManager::ObjectCacheSize::get(
+ comphelper::getProcessComponentContext()));
+ mpGlobalMgr->SetCacheTimeout(
+ officecfg::Office::Common::Cache::GraphicManager::ObjectReleaseTime::get(
+ comphelper::getProcessComponentContext()));
}
mpMgr = mpGlobalMgr;