diff options
author | Kohei Yoshida <kohei.yoshida@collabora.com> | 2013-10-23 13:17:00 -0400 |
---|---|---|
committer | Kohei Yoshida <kohei.yoshida@collabora.com> | 2013-10-23 15:44:12 -0400 |
commit | 3347f41a9b13c317c1d001e7ff501a4b0ee8f896 (patch) | |
tree | b4c9a82e46e52ad3a8d0969a10989b59bec457bd /sc/source/core/data/table2.cxx | |
parent | c1cc1861ea6a656645885938dac9e4442d96510b (diff) |
Avoid exposing the internal cell note storage outside ScDocument.
Let's try to avoid including mtvelements.hxx in document.hxx...
mtvelements.hxx is very parser-heavy, and document.hxx is included
everywhere...
Change-Id: I2768ba6e25f8ff10f61f9cfd4a7cbc4844230630
Diffstat (limited to 'sc/source/core/data/table2.cxx')
-rw-r--r-- | sc/source/core/data/table2.cxx | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/sc/source/core/data/table2.cxx b/sc/source/core/data/table2.cxx index 312aa22b77a4..5295af6c5e5c 100644 --- a/sc/source/core/data/table2.cxx +++ b/sc/source/core/data/table2.cxx @@ -1502,6 +1502,28 @@ ScPostIt* ScTable::GetNote(const SCCOL nCol, const SCROW nRow) return pDocument->GetNote(nCol, nRow, nTab); } +size_t ScTable::GetNoteCount( SCCOL nCol ) const +{ + if (!ValidCol(nCol)) + return 0; + + return aCol[nCol].GetNoteCount(); +} + +SCROW ScTable::GetNotePosition( SCCOL nCol, size_t nIndex ) const +{ + if (!ValidCol(nCol)) + return -1; + + return aCol[nCol].GetNotePosition(nIndex); +} + +void ScTable::GetAllNoteEntries( std::vector<sc::NoteEntry>& rNotes ) const +{ + for (SCCOL nCol = 0; nCol < MAXCOLCOUNT; ++nCol) + aCol[nCol].GetAllNoteEntries(rNotes); +} + CellType ScTable::GetCellType( SCCOL nCol, SCROW nRow ) const { if (ValidColRow( nCol, nRow )) |