diff options
Diffstat (limited to 'oox')
-rw-r--r-- | oox/source/helper/graphichelper.cxx | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/oox/source/helper/graphichelper.cxx b/oox/source/helper/graphichelper.cxx index 073cfe6d694f..6500f82e9a44 100644 --- a/oox/source/helper/graphichelper.cxx +++ b/oox/source/helper/graphichelper.cxx @@ -242,7 +242,8 @@ Reference< XGraphic > GraphicHelper::importGraphic( const Reference< XInputStrea aArgs[ 0 ].Name = "InputStream"; aArgs[ 0 ].Value <<= rxInStrm; aArgs[ 1 ].Name = "LazyRead"; - aArgs[ 1 ].Value <<= true; + bool bLazyRead = !pExtHeader; + aArgs[ 1 ].Value <<= bLazyRead; if ( pExtHeader && pExtHeader->mapMode > 0 ) { @@ -341,6 +342,11 @@ Reference< XGraphic > GraphicHelper::importEmbeddedGraphic( const OUString& rStr EmbeddedGraphicMap::const_iterator aIt = maEmbeddedGraphics.find( rStreamName ); if( aIt == maEmbeddedGraphics.end() ) { + // Lazy-loading doesn't work with TIFF at the moment. + WmfExternal aHeader; + if (rStreamName.endsWith(".tiff") && !pExtHeader) + pExtHeader = &aHeader; + xGraphic = importGraphic(mxStorage->openInputStream(rStreamName), pExtHeader); if( xGraphic.is() ) maEmbeddedGraphics[ rStreamName ] = xGraphic; |