diff options
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/ui/view/viewfun6.cxx | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/sc/source/ui/view/viewfun6.cxx b/sc/source/ui/view/viewfun6.cxx index 86b04f63ffbe..2a5f693bdfb5 100644 --- a/sc/source/ui/view/viewfun6.cxx +++ b/sc/source/ui/view/viewfun6.cxx @@ -127,13 +127,12 @@ void ScViewFunc::MarkAndJumpToRanges(const ScRangeList& rRanges) ScDocShell* pDocSh = pView->GetDocShell(); ScRangeList aRanges(rRanges); - ScRange* p = aRanges.front(); ScRangeList aRangesToMark; ScAddress aCurPos = pView->GetCurPos(); size_t ListSize = aRanges.size(); for ( size_t i = 0; i < ListSize; ++i ) { - p = aRanges[i]; + const ScRange* p = aRanges[i]; // Collect only those ranges that are on the same sheet as the current // cursor. if (p->aStart.Tab() == aCurPos.Tab()) @@ -144,7 +143,7 @@ void ScViewFunc::MarkAndJumpToRanges(const ScRangeList& rRanges) return; // Jump to the first range of all precedent ranges. - p = aRangesToMark.front(); + const ScRange* p = aRangesToMark.front(); lcl_jumpToRange(*p, pView, pDocSh->GetDocument()); ListSize = aRangesToMark.size(); |