[Libreoffice-commits] .: Branch 'libreoffice-3-4' - svx/source

Michael Stahl mst at kemper.freedesktop.org
Fri Oct 21 04:04:32 PDT 2011


 svx/source/svdraw/svdograf.cxx |    7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

New commits:
commit 1191c474bdf21fda5e8b8ced6b0b50286dea2391
Author: Thorsten Behrens <tbehrens-Et1tbQHTxzrQT0dZR+AlfA at public.gmane.org>
Date:   Fri Oct 21 11:14:32 2011 +0200

    Fix fdo#41995 fallout - recognize .svg in odf container
    
    Seems the graphic load code is stupid and not using the path name /
    file extension to guess file type, but only "magic byte" detection.
    Giving filter framework the path now, so that .svg actually loads.
    
    Signed-off-by: Michael Stahl <mstahl at redhat.com>

diff --git a/svx/source/svdraw/svdograf.cxx b/svx/source/svdraw/svdograf.cxx
index e51a268..56d0643 100644
--- a/svx/source/svdraw/svdograf.cxx
+++ b/svx/source/svdraw/svdograf.cxx
@@ -1299,8 +1299,11 @@ IMPL_LINK( SdrGrafObj, ImpSwapHdl, GraphicObject*, pO )
                         mbIsPreview = sal_True;
                     }
 
-                    if( !GraphicFilter::GetGraphicFilter()->ImportGraphic( aGraphic, String(), *pStream,
-                                                        GRFILTER_FORMAT_DONTKNOW, NULL, 0, pFilterData ) )
+                    if( !GraphicFilter::GetGraphicFilter()->ImportGraphic( aGraphic,
+                                                                           aStreamInfo.maUserData,
+                                                                           *pStream,
+                                                                           GRFILTER_FORMAT_DONTKNOW,
+                                                                           NULL, 0, pFilterData ) )
                     {
                         const String aUserData( pGraphic->GetUserData() );
 


More information about the Libreoffice-commits mailing list