[Libreoffice-commits] core.git: sc/source

Laurent Godard lgodard.libre at laposte.net
Thu Dec 5 05:53:28 PST 2013


 sc/source/ui/unoobj/docuno.cxx |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

New commits:
commit b561d6ef7d03f6d940d01367110f595deec7475c
Author: Laurent Godard <lgodard.libre at laposte.net>
Date:   Thu Dec 5 12:04:31 2013 +0100

    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 at googlemail.com>
    Reviewed-by: Markus Mohrhard <markus.mohrhard at googlemail.com>

diff --git a/sc/source/ui/unoobj/docuno.cxx b/sc/source/ui/unoobj/docuno.cxx
index 56cd857..54f40d0 100644
--- a/sc/source/ui/unoobj/docuno.cxx
+++ b/sc/source/ui/unoobj/docuno.cxx
@@ -3605,7 +3605,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;
 }


More information about the Libreoffice-commits mailing list