summaryrefslogtreecommitdiff
path: root/embeddedobj
diff options
context:
space:
mode:
authorJan Holesovsky <kendy@collabora.com>2014-03-04 22:49:08 +0100
committerMichael Stahl <mstahl@redhat.com>2014-05-12 18:37:29 +0200
commit4bf27036d6b8ff56bdc76325a874f17ad8f9ddcb (patch)
treec21d9c66e8fa0ae522f601893a0cb3ed949196a9 /embeddedobj
parentc4e10ad83fe1fa92a115327c1909218f5dc8c8bd (diff)
OLE: Turn an OSL_ENSURE() into a real condition (related: fdo#65631)
This is part of some STAMPIT workaround; no idea what it is, but for sure it causes problems with PowerPoint OLE in Writer - so let's avoid updating if it is not "STAMPIT". This appears to help for the problem in fdo#65631 comment #9 on master, let's see if the same is true if it's backported to 4.2... (cherry picked from commit a94e973bf5b5d0755a53881867961691633a4cbd) Signed-off-by: Michael Stahl <mstahl@redhat.com> Change-Id: I266b419ba3461c547f7ee8e447ef64a47a8511e8
Diffstat (limited to 'embeddedobj')
-rw-r--r--embeddedobj/source/msole/olepersist.cxx11
1 files changed, 5 insertions, 6 deletions
diff --git a/embeddedobj/source/msole/olepersist.cxx b/embeddedobj/source/msole/olepersist.cxx
index 528d0fc5bdfa..077a847dd65d 100644
--- a/embeddedobj/source/msole/olepersist.cxx
+++ b/embeddedobj/source/msole/olepersist.cxx
@@ -885,13 +885,12 @@ void OleEmbeddedObject::OnViewChanged_Impl()
// - if the verb execution is in progress and the view is changed the object will be stored
// after the execution, so there is no need to send the notification.
// - the STAMPIT object can never be active.
- if ( m_aVerbExecutionController.CanDoNotification()
- && m_pOleComponent && m_nUpdateMode == embed::EmbedUpdateModes::ALWAYS_UPDATE )
+ if (m_aVerbExecutionController.CanDoNotification() &&
+ m_pOleComponent && m_nUpdateMode == embed::EmbedUpdateModes::ALWAYS_UPDATE &&
+ (MimeConfigurationHelper::ClassIDsEqual(m_aClassID, MimeConfigurationHelper::GetSequenceClassID(0x852ee1c9, 0x9058, 0x44ba, 0x8c, 0x6c, 0x0c, 0x5f, 0xc6, 0x6b, 0xdb, 0x8d)) ||
+ MimeConfigurationHelper::ClassIDsEqual(m_aClassID, MimeConfigurationHelper::GetSequenceClassID(0xcf1b4491, 0xbea3, 0x4c9f, 0xa7, 0x0f, 0x22, 0x1b, 0x1e, 0xca, 0xef, 0x3e)))
+ )
{
- OSL_ENSURE( MimeConfigurationHelper::ClassIDsEqual( m_aClassID, MimeConfigurationHelper::GetSequenceClassID( 0x852ee1c9, 0x9058, 0x44ba, 0x8c,0x6c,0x0c,0x5f,0xc6,0x6b,0xdb,0x8d ) )
- || MimeConfigurationHelper::ClassIDsEqual( m_aClassID, MimeConfigurationHelper::GetSequenceClassID( 0xcf1b4491, 0xbea3, 0x4c9f, 0xa7,0x0f,0x22,0x1b,0x1e,0xca,0xef,0x3e ) ),
- "Expected to be triggered for STAMPIT only! Please contact developers!\n" );
-
// The view is changed while the object is in running state, save the new object
m_xCachedVisualRepresentation = uno::Reference< io::XStream >();
SaveObject_Impl();