summaryrefslogtreecommitdiff
path: root/embeddedobj/source/commonembedding/embedobj.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'embeddedobj/source/commonembedding/embedobj.cxx')
-rw-r--r--embeddedobj/source/commonembedding/embedobj.cxx7
1 files changed, 5 insertions, 2 deletions
diff --git a/embeddedobj/source/commonembedding/embedobj.cxx b/embeddedobj/source/commonembedding/embedobj.cxx
index cb76f5ff3c..868f77836f 100644
--- a/embeddedobj/source/commonembedding/embedobj.cxx
+++ b/embeddedobj/source/commonembedding/embedobj.cxx
@@ -37,7 +37,7 @@
#include <com/sun/star/embed/XInplaceClient.hpp>
#include <com/sun/star/embed/XWindowSupplier.hpp>
#include <com/sun/star/embed/StateChangeInProgressException.hpp>
-
+#include <com/sun/star/embed/Aspects.hpp>
#include <com/sun/star/awt/XWindowPeer.hpp>
#include <com/sun/star/util/XCloseBroadcaster.hpp>
@@ -225,6 +225,9 @@ void OCommonEmbeddedObject::SwitchStateTo_Impl( sal_Int32 nNextState )
{
if ( nNextState == embed::EmbedStates::LOADED )
{
+ m_nClonedMapUnit = m_pDocHolder->GetMapUnit( embed::Aspects::MSOLE_CONTENT );
+ m_bHasClonedSize = m_pDocHolder->GetExtent( embed::Aspects::MSOLE_CONTENT, &m_aClonedSize );
+
// actually frame should not exist at this point
m_pDocHolder->CloseDocument( sal_False, sal_False );
@@ -447,7 +450,7 @@ void SAL_CALL OCommonEmbeddedObject::changeState( sal_Int32 nNewState )
uno::Reference< uno::XInterface >( static_cast< ::cppu::OWeakObject* >(this) ) );
sal_Int32 nOldState = m_nObjectState;
-
+
if ( m_nTargetState != -1 )
{
// means that the object is currently trying to reach the target state