summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLaurent Godard <lgodard.libre@laposte.net>2013-12-05 12:04:31 +0100
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2013-12-18 12:42:11 +0100
commit30b34a5dfde0a976c611b32ae1058412395f5bf3 (patch)
treed475171718d9ec7a56df9dc19802c16bf2a5eab0
parentfad39087a742e30f4a30c0d223f84b21a32d6170 (diff)
counting notes is per table, not on the whole document
Change-Id: Id4afa4eee961f159f8ea8caeac620d101cfb103e Reviewed-on: https://gerrit.libreoffice.org/6941 Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com> Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
-rw-r--r--sc/source/ui/unoobj/docuno.cxx5
1 files changed, 4 insertions, 1 deletions
diff --git a/sc/source/ui/unoobj/docuno.cxx b/sc/source/ui/unoobj/docuno.cxx
index 2b4d3e25ad70..0d39c5ee0e1f 100644
--- a/sc/source/ui/unoobj/docuno.cxx
+++ b/sc/source/ui/unoobj/docuno.cxx
@@ -3615,7 +3615,10 @@ sal_Int32 SAL_CALL ScAnnotationsObj::getCount() throw(uno::RuntimeException)
if (pDocShell)
{
ScDocument* pDoc = pDocShell->GetDocument();
- nCount = pDoc->CountNotes();
+ const ScRangeList aRangeList( ScRange( 0, 0, nTab, MAXCOL, MAXROW, nTab) );
+ std::vector<sc::NoteEntry> rNotes;
+ pDoc->GetNotesInRange(aRangeList, rNotes);
+ nCount = rNotes.size();
}
return nCount;
}