[Libreoffice-commits] core.git: sw/inc sw/source
Bjoern Michaelsen
bjoern.michaelsen at canonical.com
Sun Dec 4 09:01:10 UTC 2016
sw/inc/frmfmt.hxx | 3 ++-
sw/source/core/draw/dcontact.cxx | 3 +++
sw/source/core/frmedt/fefly1.cxx | 6 +-----
3 files changed, 6 insertions(+), 6 deletions(-)
New commits:
commit 7afedc48aed8a31aa0f376e7e4505e48ddd3a99f
Author: Bjoern Michaelsen <bjoern.michaelsen at canonical.com>
Date: Thu Dec 1 13:26:42 2016 +0100
use proper message passing
Change-Id: Ibeb0aff07aec223f274932f2b3a492e58db09a02
Reviewed-on: https://gerrit.libreoffice.org/31488
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Björn Michaelsen <bjoern.michaelsen at canonical.com>
diff --git a/sw/inc/frmfmt.hxx b/sw/inc/frmfmt.hxx
index 12df535..a0110c6 100644
--- a/sw/inc/frmfmt.hxx
+++ b/sw/inc/frmfmt.hxx
@@ -238,7 +238,8 @@ namespace sw
{
enum class DrawFrameFormatHintId {
DYING,
- PREPPASTING
+ PREPPASTING,
+ PAGE_OUT_OF_BOUNDS
};
struct SW_DLLPUBLIC DrawFrameFormatHint final: SfxHint
{
diff --git a/sw/source/core/draw/dcontact.cxx b/sw/source/core/draw/dcontact.cxx
index 06287d0..672cf98 100644
--- a/sw/source/core/draw/dcontact.cxx
+++ b/sw/source/core/draw/dcontact.cxx
@@ -1539,6 +1539,9 @@ void SwDrawContact::SwClientNotify(const SwModify& rMod, const SfxHint& rHint)
case sw::DrawFrameFormatHintId::PREPPASTING:
MoveObjToVisibleLayer(GetMaster());
break;
+ case sw::DrawFrameFormatHintId::PAGE_OUT_OF_BOUNDS:
+ DisconnectFromLayout();
+ break;
default:
SAL_WARN("sw.core", "unhandled DrawFrameFormatHintId");
}
diff --git a/sw/source/core/frmedt/fefly1.cxx b/sw/source/core/frmedt/fefly1.cxx
index e39fc6a..9083b2e 100644
--- a/sw/source/core/frmedt/fefly1.cxx
+++ b/sw/source/core/frmedt/fefly1.cxx
@@ -961,11 +961,7 @@ void SwFEShell::SetPageObjsNewPage( std::vector<SwFrameFormat*>& rFillArr )
if( sal_uInt16(nNewPage) > nMaxPage )
{
if ( RES_DRAWFRMFMT == pFormat->Which() )
- {
- SwContact *pCon = pFormat->FindContactObj();
- if( pCon )
- static_cast<SwDrawContact*>(pCon)->DisconnectFromLayout();
- }
+ pFormat->CallSwClientNotify(sw::DrawFrameFormatHint(sw::DrawFrameFormatHintId::PAGE_OUT_OF_BOUNDS));
else
pFormat->DelFrames();
bTmpAssert = true;
More information about the Libreoffice-commits
mailing list