summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCédric Bosdonnat <cedric.bosdonnat.ooo@free.fr>2012-01-09 18:15:11 +0100
committerCédric Bosdonnat <cedric.bosdonnat.ooo@free.fr>2012-01-09 18:20:35 +0100
commit4463a523ae78a9eff1776668825ec6be944c1574 (patch)
tree35a8530295a200b06daa68fa07702d3e7b901647
parentd710f11d76cd8728980824db1518d4d20e649727 (diff)
fdo#36681: refresh the layout after inserting a picture
-rw-r--r--sw/source/core/frmedt/fefly1.cxx6
1 files changed, 6 insertions, 0 deletions
diff --git a/sw/source/core/frmedt/fefly1.cxx b/sw/source/core/frmedt/fefly1.cxx
index 97c6a5d67f00..473f6f33bb65 100644
--- a/sw/source/core/frmedt/fefly1.cxx
+++ b/sw/source/core/frmedt/fefly1.cxx
@@ -846,6 +846,12 @@ void SwFEShell::Insert( const String& rGrfName, const String& rFltName,
const Point aPt( GetCrsrDocPos() );
SwFlyFrm* pFrm = pFmt->GetFrm( &aPt );
+ // Invalidate the content and layout to refresh the picture anchoring
+ // properly
+ SwPageFrm* pPageFrm = pFrm->FindPageFrmOfAnchor();
+ pPageFrm->InvalidateFlyLayout();
+ pPageFrm->InvalidateCntnt();
+
if( pFrm )
SelectFlyFrm( *pFrm, sal_True );
else