summaryrefslogtreecommitdiff
path: root/sc/source/filter/xml/xmlcelli.cxx
diff options
context:
space:
mode:
authorKohei Yoshida <kohei.yoshida@gmail.com>2013-03-19 12:51:47 -0400
committerKohei Yoshida <kohei.yoshida@gmail.com>2013-03-19 13:40:27 -0400
commit20c4921e901d84a7ef8835ee192e1a7a4b62ee61 (patch)
treec298901717bf1297e1d50c19f1e1347359105c89 /sc/source/filter/xml/xmlcelli.cxx
parentd0314afa2fef363eba06e98c70ecdc83e690dcd0 (diff)
Remove use of ScBaseCell and its derivatives outside ScDocument.
This is still work in progress. Change-Id: Ifcdbefbdd307a2a8819b073d896e90a16980781e
Diffstat (limited to 'sc/source/filter/xml/xmlcelli.cxx')
-rw-r--r--sc/source/filter/xml/xmlcelli.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/sc/source/filter/xml/xmlcelli.cxx b/sc/source/filter/xml/xmlcelli.cxx
index 7126f144af28..19b9041530eb 100644
--- a/sc/source/filter/xml/xmlcelli.cxx
+++ b/sc/source/filter/xml/xmlcelli.cxx
@@ -1053,14 +1053,14 @@ void ScXMLTableRowCellContext::PutTextCell( const ScAddress& rCurrentPos,
// This edit engine uses the SfxItemPool instance returned
// from pDoc->GetEditPool() to create the text object, which
// is a prerequisite for using this constructor of ScEditCell.
- pNewCell = new ScEditCell(mpEditEngine->CreateTextObject(), pDoc);
+ pDoc->SetEditText(rCurrentPos, mpEditEngine->CreateTextObject());
}
}
else if ( nCurrentCol > 0 && pOUText && !pOUText->isEmpty() )
pNewCell = ScBaseCell::CreateTextCell( *pOUText, pDoc );
bDoIncrement = pNewCell != NULL;
- if ( bDoIncrement )
+ if (bDoIncrement && pNewCell)
pDoc->PutCell( rCurrentPos, pNewCell );
}
// #i56027# This is about setting simple text, not edit cells,