sw/inc/swevent.hxx | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-)
New commits: commit e7c6301e707fcc461bdda5ac74c7499f568ff716 Author: Michael Stahl <[email protected]> Date: Wed Jun 28 16:30:28 2017 +0200 tdf#108826 sw: also handle RES_REMOVE_UNO_OBJECT in SwCallMouseEvent This is sent from SwUndoFlyBase::DelFly(); the SwFrameFormat isn't deleted in this case but it's no longer part of the document, so an UI class like SwCallMouseEvent should stop pointing to it. Change-Id: I05349271d14bb1948ea30528cd85c68ed638f28e diff --git a/sw/inc/swevent.hxx b/sw/inc/swevent.hxx index 3eb0fb8bfa23..8cb2e2b55c5e 100644 --- a/sw/inc/swevent.hxx +++ b/sw/inc/swevent.hxx @@ -130,9 +130,11 @@ struct SwCallMouseEvent { assert(EVENT_OBJECT_IMAGE == eType || EVENT_OBJECT_URLITEM == eType || EVENT_OBJECT_IMAGEMAP == eType); SwClient::Modify(pOldValue, pNewValue); - if (!GetRegisteredIn() || - (RES_FMT_CHG == pOldValue->Which() - && static_cast<SwFormatChg const*>(pOldValue)->pChangedFormat == PTR.pFormat)) + if (!GetRegisteredIn() + || (RES_FMT_CHG == pOldValue->Which() + && static_cast<SwFormatChg const*>(pOldValue)->pChangedFormat == PTR.pFormat) + || (RES_REMOVE_UNO_OBJECT == pOldValue->Which() + && static_cast<SwPtrMsgPoolItem const*>(pOldValue)->pObject == PTR.pFormat)) { Clear(); } _______________________________________________ Libreoffice-commits mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
