Kaydet (Commit) 68b64b41 authored tarafından Bjoern Michaelsen's avatar Bjoern Michaelsen Kaydeden (comit) Björn Michaelsen

use proper message passing

Change-Id: I0c6610308f75a57e517b233db66c66b34eb25189
Reviewed-on: https://gerrit.libreoffice.org/31492Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarBjörn Michaelsen <bjoern.michaelsen@canonical.com>
üst 7afedc48
...@@ -239,7 +239,8 @@ namespace sw ...@@ -239,7 +239,8 @@ namespace sw
enum class DrawFrameFormatHintId { enum class DrawFrameFormatHintId {
DYING, DYING,
PREPPASTING, PREPPASTING,
PAGE_OUT_OF_BOUNDS PREP_INSERT_FLY,
PAGE_OUT_OF_BOUNDS,
}; };
struct SW_DLLPUBLIC DrawFrameFormatHint final: SfxHint struct SW_DLLPUBLIC DrawFrameFormatHint final: SfxHint
{ {
......
...@@ -1539,6 +1539,12 @@ void SwDrawContact::SwClientNotify(const SwModify& rMod, const SfxHint& rHint) ...@@ -1539,6 +1539,12 @@ void SwDrawContact::SwClientNotify(const SwModify& rMod, const SfxHint& rHint)
case sw::DrawFrameFormatHintId::PREPPASTING: case sw::DrawFrameFormatHintId::PREPPASTING:
MoveObjToVisibleLayer(GetMaster()); MoveObjToVisibleLayer(GetMaster());
break; break;
case sw::DrawFrameFormatHintId::PREP_INSERT_FLY:
InsertMasterIntoDrawPage();
// #i40845# - follow-up of #i35635#
// move object to visible layer
MoveObjToVisibleLayer(GetMaster());
break;
case sw::DrawFrameFormatHintId::PAGE_OUT_OF_BOUNDS: case sw::DrawFrameFormatHintId::PAGE_OUT_OF_BOUNDS:
DisconnectFromLayout(); DisconnectFromLayout();
break; break;
......
...@@ -65,17 +65,7 @@ void SwUndoFlyBase::InsFly(::sw::UndoRedoContext & rContext, bool bShowSelFrame) ...@@ -65,17 +65,7 @@ void SwUndoFlyBase::InsFly(::sw::UndoRedoContext & rContext, bool bShowSelFrame)
// OD 26.06.2003 #108784# - insert 'master' drawing object into drawing page // OD 26.06.2003 #108784# - insert 'master' drawing object into drawing page
if ( RES_DRAWFRMFMT == pFrameFormat->Which() ) if ( RES_DRAWFRMFMT == pFrameFormat->Which() )
{ pFrameFormat->CallSwClientNotify(sw::DrawFrameFormatHint(sw::DrawFrameFormatHintId::PREP_INSERT_FLY));
SwDrawContact* pDrawContact =
static_cast<SwDrawContact*>(pFrameFormat->FindContactObj());
if ( pDrawContact )
{
pDrawContact->InsertMasterIntoDrawPage();
// #i40845# - follow-up of #i35635#
// move object to visible layer
pDrawContact->MoveObjToVisibleLayer( pDrawContact->GetMaster() );
}
}
SwFormatAnchor aAnchor( (RndStdIds)nRndId ); SwFormatAnchor aAnchor( (RndStdIds)nRndId );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment