summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@suse.cz>2012-08-13 12:23:05 +0200
committerPetr Mladek <pmladek@suse.cz>2012-08-14 16:06:54 +0200
commit1067832bbfae15811ff2e1d478139b5af283de51 (patch)
treef51642a78ff7a11b4da497d8c89502f0d4002afa
parent0eeab7204ac244bebb0f8c4d8a8891037423534a (diff)
fdo#47495 fix RTF import of multiple shapes inside textframes
(cherry-picked from commit ad72a47dbd16f65316432df71dffe3b9b835fcc7) Change-Id: Iee8541ff9e88139648d45f08968476f2b1d4e1b3 Signed-off-by: Petr Mladek <pmladek@suse.cz>
-rw-r--r--writerfilter/source/rtftok/rtfdocumentimpl.cxx5
1 files changed, 4 insertions, 1 deletions
diff --git a/writerfilter/source/rtftok/rtfdocumentimpl.cxx b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
index 135550178289..aa58eaa9650a 100644
--- a/writerfilter/source/rtftok/rtfdocumentimpl.cxx
+++ b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
@@ -3411,7 +3411,8 @@ int RTFDocumentImpl::popState()
bFaltEnd = true;
}
else if (m_aStates.top().nDestinationState == DESTINATION_FLYMAINCONTENT
- || m_aStates.top().nDestinationState == DESTINATION_SHPPICT)
+ || m_aStates.top().nDestinationState == DESTINATION_SHPPICT
+ || aState.nDestinationState == DESTINATION_SHAPE)
bPopFrame = true;
else if (m_aStates.top().nDestinationState == DESTINATION_DRAWINGOBJECT && m_aStates.top().aDrawingObject.xShape.is())
{
@@ -3436,6 +3437,8 @@ int RTFDocumentImpl::popState()
{
m_aStates.top().resetFrame();
parBreak();
+ // Save this state for later use, so we only reset frame status only for the first shape inside a frame.
+ aState = m_aStates.top();
m_bNeedPap = true;
}