diff options
author | Frank Schoenheit [fs] <frank.schoenheit@sun.com> | 2010-01-26 13:19:11 +0100 |
---|---|---|
committer | Frank Schoenheit [fs] <frank.schoenheit@sun.com> | 2010-01-26 13:19:11 +0100 |
commit | 6d315e9820439bd8566491da9fcd5fcb28174db7 (patch) | |
tree | 1fb380a34b086772e70c08825f3dd1dad59046de /embeddedobj | |
parent | 05ca2f4f9fa6195a27f281006125c6191d2c9631 (diff) |
autorecovery: mav sanctioned the approach of the (now so-called) RecoveryStorage
Diffstat (limited to 'embeddedobj')
-rw-r--r-- | embeddedobj/source/commonembedding/miscobj.cxx | 2 | ||||
-rw-r--r-- | embeddedobj/source/commonembedding/persistence.cxx | 13 | ||||
-rw-r--r-- | embeddedobj/source/inc/commonembobj.hxx | 2 |
3 files changed, 9 insertions, 8 deletions
diff --git a/embeddedobj/source/commonembedding/miscobj.cxx b/embeddedobj/source/commonembedding/miscobj.cxx index f666cfc4912a..63863e54f2fd 100644 --- a/embeddedobj/source/commonembedding/miscobj.cxx +++ b/embeddedobj/source/commonembedding/miscobj.cxx @@ -647,7 +647,7 @@ void SAL_CALL OCommonEmbeddedObject::close( sal_Bool bDeliverOwnership ) } m_xObjectStorage.clear(); - m_xObjectLoadStorage.clear(); + m_xRecoveryStorage.clear(); } m_bClosed = sal_True; // the closing succeeded diff --git a/embeddedobj/source/commonembedding/persistence.cxx b/embeddedobj/source/commonembedding/persistence.cxx index a2c3d2bcef64..e9aa0edd0ec8 100644 --- a/embeddedobj/source/commonembedding/persistence.cxx +++ b/embeddedobj/source/commonembedding/persistence.cxx @@ -550,9 +550,9 @@ uno::Reference< util::XCloseable > OCommonEmbeddedObject::LoadDocumentFromStorag if ( xDoc.is() ) { - if ( m_xObjectLoadStorage.is() ) + if ( m_xRecoveryStorage.is() ) { - xDoc->loadFromStorage( m_xObjectLoadStorage, aArgs ); + xDoc->loadFromStorage( m_xRecoveryStorage, aArgs ); SwitchDocToStorage_Impl( xDoc, m_xObjectStorage ); } else @@ -736,12 +736,13 @@ void OCommonEmbeddedObject::SaveObject_Impl() void OCommonEmbeddedObject::SwitchDocToStorage_Impl( const uno::Reference< document::XStorageBasedDocument >& xDoc, const uno::Reference< embed::XStorage >& xStorage ) { xDoc->switchToStorage( xStorage ); + uno::Reference< util::XModifiable > xModif( xDoc, uno::UNO_QUERY ); if ( xModif.is() ) xModif->setModified( sal_False ); - if ( m_xObjectLoadStorage.is() ) - m_xObjectLoadStorage.clear(); + if ( m_xRecoveryStorage.is() ) + m_xRecoveryStorage.clear(); } //------------------------------------------------------ @@ -1077,9 +1078,9 @@ void SAL_CALL OCommonEmbeddedObject::setPersistentEntry( { OSL_VERIFY( lObjArgs[nObjInd].Value >>= m_bDocumentRecoverySupport ); } - else if ( lObjArgs[nObjInd].Name.equalsAscii( "RecoverFromStorage" ) ) + else if ( lObjArgs[nObjInd].Name.equalsAscii( "RecoveryStorage" ) ) { - OSL_VERIFY( lObjArgs[nObjInd].Value >>= m_xObjectLoadStorage ); + OSL_VERIFY( lObjArgs[nObjInd].Value >>= m_xRecoveryStorage ); } diff --git a/embeddedobj/source/inc/commonembobj.hxx b/embeddedobj/source/inc/commonembobj.hxx index 69cdb3d4c7a3..2ba0e5cd4aca 100644 --- a/embeddedobj/source/inc/commonembobj.hxx +++ b/embeddedobj/source/inc/commonembobj.hxx @@ -151,7 +151,7 @@ protected: ::rtl::OUString m_aEntryName; ::com::sun::star::uno::Reference< ::com::sun::star::embed::XStorage > m_xParentStorage; ::com::sun::star::uno::Reference< ::com::sun::star::embed::XStorage > m_xObjectStorage; - ::com::sun::star::uno::Reference< ::com::sun::star::embed::XStorage > m_xObjectLoadStorage; + ::com::sun::star::uno::Reference< ::com::sun::star::embed::XStorage > m_xRecoveryStorage; // link related stuff ::rtl::OUString m_aLinkURL; |