diff options
author | Kohei Yoshida <kohei.yoshida@collabora.com> | 2013-10-23 18:12:09 -0400 |
---|---|---|
committer | Kohei Yoshida <kohei.yoshida@collabora.com> | 2013-10-23 19:01:19 -0400 |
commit | 5b483ed15d70bdc34b9520632ee569db0e6c4f9d (patch) | |
tree | 42ee1211cc729563a1e1b5881f2259436aec2724 | |
parent | f068f1ae32f4243d8f8f8b90209508b1b5906548 (diff) |
Cell note deletion should happen even when no cells exist in the column.
This fixes one of the API test breakages.
Change-Id: I8168d490ec5d519e151a74fb8c4343337262f15b
-rw-r--r-- | sc/source/core/data/column3.cxx | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/sc/source/core/data/column3.cxx b/sc/source/core/data/column3.cxx index c90a33e11644..73bcf2d56af6 100644 --- a/sc/source/core/data/column3.cxx +++ b/sc/source/core/data/column3.cxx @@ -600,14 +600,18 @@ void ScColumn::DeleteArea(SCROW nStartRow, SCROW nEndRow, sal_uInt16 nDelFlag) aBlockPos.miCellTextAttrPos = maCellTextAttrs.begin(); aBlockPos.miCellNotePos = maCellNotes.begin(); - if ( nDelFlag & IDF_NOTE ) - DeleteCellNotes( aBlockPos, nStartRow, nEndRow ); - // Delete the cells for real. std::for_each(aSpans.begin(), aSpans.end(), EmptyCells(aBlockPos, *this)); CellStorageModified(); } + if (nDelFlag & IDF_NOTE) + { + sc::ColumnBlockPosition aBlockPos; + aBlockPos.miCellNotePos = maCellNotes.begin(); + DeleteCellNotes(aBlockPos, nStartRow, nEndRow); + } + if ( nDelFlag & IDF_EDITATTR ) { OSL_ENSURE( nContFlag == 0, "DeleteArea: Wrong Flags" ); |