diff options
author | Kohei Yoshida <kohei.yoshida@collabora.com> | 2014-01-29 11:42:27 -0500 |
---|---|---|
committer | Kohei Yoshida <kohei.yoshida@collabora.com> | 2014-01-29 15:46:05 -0500 |
commit | 8a36879eaf0977448b113c2239014d2e2b7ab258 (patch) | |
tree | b74c0651240d114164b8af68821272aef0c885e9 /sc/source/core/data | |
parent | 76599f3ca36810379a2dda7826aa3cd0f4441cfb (diff) |
fdo#74014: More on broadcasting at appropriate places.
Also, call PostDataChanged() to re-paint re-calculated formula cells.
Change-Id: I63161329d4bfe937f754773fd68c37e3836c4950
Diffstat (limited to 'sc/source/core/data')
-rw-r--r-- | sc/source/core/data/documen7.cxx | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/sc/source/core/data/documen7.cxx b/sc/source/core/data/documen7.cxx index b8f691b91a00..210d87bd64d7 100644 --- a/sc/source/core/data/documen7.cxx +++ b/sc/source/core/data/documen7.cxx @@ -104,6 +104,31 @@ void ScDocument::Broadcast( const ScHint& rHint ) } } +void ScDocument::BroadcastCells( const ScRange& rRange, sal_uLong nHint ) +{ + CellContentModified(); + + ScBulkBroadcast aBulkBroadcast(pBASM); + + ScHint aHint(nHint, ScAddress()); + ScAddress& rPos = aHint.GetAddress(); + for (SCTAB nTab = rRange.aStart.Tab(); nTab <= rRange.aEnd.Tab(); ++nTab) + { + rPos.SetTab(nTab); + for (SCCOL nCol = rRange.aStart.Col(); nCol <= rRange.aEnd.Col(); ++nCol) + { + rPos.SetCol(nCol); + for (SCROW nRow = rRange.aStart.Row(); nRow <= rRange.aEnd.Row(); ++nRow) + { + rPos.SetRow(nRow); + Broadcast(aHint); + } + } + } + + BroadcastUno(SfxSimpleHint(SC_HINT_DATACHANGED)); +} + void ScDocument::AreaBroadcast( const ScHint& rHint ) { if ( !pBASM ) |