[Libreoffice-commits] .: 2 commits - svx/source writerfilter/source

Cédric Bosdonnat cbosdo at kemper.freedesktop.org
Wed Nov 23 02:24:49 PST 2011


 svx/source/unodraw/unoshape.cxx                |    5 ++++-
 writerfilter/source/filter/RtfFilter.cxx       |    7 ++++++-
 writerfilter/source/rtftok/rtfdocumentimpl.cxx |    2 +-
 3 files changed, 11 insertions(+), 3 deletions(-)

New commits:
commit e846db644868651556b38f91737b81c43f3c4f3c
Author: Cédric Bosdonnat <cedric.bosdonnat.ooo at free.fr>
Date:   Wed Nov 23 11:22:28 2011 +0100

    RTF: OLE object import with graphic result fixed, the file can now be opened

diff --git a/writerfilter/source/rtftok/rtfdocumentimpl.cxx b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
index 2a46fb0..2e31bc7 100644
--- a/writerfilter/source/rtftok/rtfdocumentimpl.cxx
+++ b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
@@ -597,7 +597,7 @@ int RTFDocumentImpl::resolvePict(bool bInline)
                     m_xContext),
                 uno::UNO_QUERY_THROW);
         uno::Reference<graphic::XGraphic> xGraphic = xGraphicProvider->queryGraphic(aMediaProperties);
-        xPropertySet->setPropertyValue(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Bitmap")), uno::Any(xGraphic));
+        xPropertySet->setPropertyValue(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Graphic")), uno::Any(xGraphic));
 
         RTFValue::Pointer_t pShapeValue(new RTFValue(xShape));
         m_aObjectAttributes->push_back(make_pair(NS_ooxml::LN_shape, pShapeValue));
commit a45c82f930c1224928fd0a8f9ca3690ddd162366
Author: Cédric Bosdonnat <cedric.bosdonnat.ooo at free.fr>
Date:   Tue Nov 22 18:01:32 2011 +0100

    Show some exception message when getting one in RtfFilter

diff --git a/svx/source/unodraw/unoshape.cxx b/svx/source/unodraw/unoshape.cxx
index e3bfaf3..b676551 100644
--- a/svx/source/unodraw/unoshape.cxx
+++ b/svx/source/unodraw/unoshape.cxx
@@ -1720,7 +1720,10 @@ void SAL_CALL SvxShape::_setPropertyValue( const OUString& rPropertyName, const
             throw beans::UnknownPropertyException();
 
         if( (pMap->nFlags & beans::PropertyAttribute::READONLY ) != 0 )
-            throw beans::PropertyVetoException();
+            throw beans::PropertyVetoException( rtl::OUString::createFromAscii(
+                        OSL_FORMAT( "Readonly property can't be set: %s",
+                            rtl::OUStringToOString( rPropertyName, RTL_TEXTENCODING_UTF8 ).getStr() ) ),
+                        uno::Reference< drawing::XShape >( this ) );
 
         mpModel->SetChanged();
 
diff --git a/writerfilter/source/filter/RtfFilter.cxx b/writerfilter/source/filter/RtfFilter.cxx
index 4b214ab..8786539 100644
--- a/writerfilter/source/filter/RtfFilter.cxx
+++ b/writerfilter/source/filter/RtfFilter.cxx
@@ -99,8 +99,13 @@ sal_Bool RtfFilter::filter( const uno::Sequence< beans::PropertyValue >& aDescri
 #endif
         return sal_True;
     }
-    catch (const uno::Exception&)
+    catch (const uno::Exception& e)
     {
+#if OSL_DEBUG_LEVEL > 1
+        OSL_TRACE( "Exception caught: %s",
+                rtl::OUStringToOString( e.Message, RTL_TEXTENCODING_UTF8 ).getStr() );
+#endif
+        (void)e;
         return sal_False;
     }
 }


More information about the Libreoffice-commits mailing list