[Libreoffice-commits] .: sc/source
Caolán McNamara
caolan at kemper.freedesktop.org
Tue Jul 5 05:49:01 PDT 2011
sc/source/ui/docshell/docfunc.cxx | 8 ++++----
sc/source/ui/docshell/editable.cxx | 2 +-
sc/source/ui/vba/vbawindow.cxx | 2 +-
sc/source/ui/view/pfuncache.cxx | 2 +-
sc/source/ui/view/tabvwshf.cxx | 2 +-
sc/source/ui/view/viewfun2.cxx | 2 +-
sc/source/ui/view/viewfun3.cxx | 6 +++---
7 files changed, 12 insertions(+), 12 deletions(-)
New commits:
commit 430ceab8f14a937e401fb934a097d3adf3dc54d9
Author: Caolán McNamara <caolanm at redhat.com>
Date: Tue Jul 5 13:35:56 2011 +0100
yet more iterator->const_iterator
diff --git a/sc/source/ui/docshell/docfunc.cxx b/sc/source/ui/docshell/docfunc.cxx
index b9a0728..9f50304 100644
--- a/sc/source/ui/docshell/docfunc.cxx
+++ b/sc/source/ui/docshell/docfunc.cxx
@@ -633,7 +633,7 @@ sal_Bool ScDocFunc::DeleteContents( const ScMarkData& rMark, sal_uInt16 nFlags,
{
bObjects = sal_True;
SCTAB nTabCount = pDoc->GetTableCount();
- ScMarkData::iterator itr = rMark.begin(), itrEnd = rMark.end();
+ ScMarkData::const_iterator itr = rMark.begin(), itrEnd = rMark.end();
for (; itr != itrEnd && *itr < nTabCount; ++itr)
if (pDoc->IsTabProtected(*itr))
bObjects = false;
@@ -740,7 +740,7 @@ sal_Bool ScDocFunc::TransliterateText( const ScMarkData& rMark, sal_Int32 nType,
ScDocument* pUndoDoc = new ScDocument( SCDOCMODE_UNDO );
pUndoDoc->InitUndo( pDoc, nStartTab, nStartTab );
- ScMarkData::iterator itr = rMark.begin(), itrEnd = rMark.end();
+ ScMarkData::const_iterator itr = rMark.begin(), itrEnd = rMark.end();
for (; itr != itrEnd && *itr < nTabCount; ++itr)
if (*itr != nStartTab)
pUndoDoc->AddUndoTab( *itr, *itr );
@@ -1323,7 +1323,7 @@ sal_Bool ScDocFunc::ApplyStyle( const ScMarkData& rMark, const String& rStyleNam
SCTAB nStartTab = aMultiRange.aStart.Tab();
SCTAB nTabCount = pDoc->GetTableCount();
pUndoDoc->InitUndo( pDoc, nStartTab, nStartTab );
- ScMarkData::iterator itr = rMark.begin(), itrEnd = rMark.end();
+ ScMarkData::const_iterator itr = rMark.begin(), itrEnd = rMark.end();
for (; itr != itrEnd && *itr < nTabCount; ++itr)
if (*itr != nStartTab)
pUndoDoc->AddUndoTab( *itr, *itr );
@@ -3623,7 +3623,7 @@ sal_Bool ScDocFunc::ChangeIndent( const ScMarkData& rMark, sal_Bool bIncrement,
ScDocument* pUndoDoc = new ScDocument( SCDOCMODE_UNDO );
pUndoDoc->InitUndo( pDoc, nStartTab, nStartTab );
- ScMarkData::iterator itr = rMark.begin(), itrEnd = rMark.end();
+ ScMarkData::const_iterator itr = rMark.begin(), itrEnd = rMark.end();
for (; itr != itrEnd && *itr < nTabCount; ++itr)
if (*itr != nStartTab)
pUndoDoc->AddUndoTab( *itr, *itr );
diff --git a/sc/source/ui/docshell/editable.cxx b/sc/source/ui/docshell/editable.cxx
index b7407c0..58bf566 100644
--- a/sc/source/ui/docshell/editable.cxx
+++ b/sc/source/ui/docshell/editable.cxx
@@ -104,7 +104,7 @@ void ScEditableTester::TestSelectedBlock( ScDocument* pDoc,
const ScMarkData& rMark )
{
SCTAB nTabCount = pDoc->GetTableCount();
- ScMarkData::iterator itr = rMark.begin(), itrEnd = rMark.end();
+ ScMarkData::const_iterator itr = rMark.begin(), itrEnd = rMark.end();
for (; itr != itrEnd && *itr < nTabCount; ++itr)
TestBlock( pDoc, *itr, nStartCol, nStartRow, nEndCol, nEndRow );
}
diff --git a/sc/source/ui/vba/vbawindow.cxx b/sc/source/ui/vba/vbawindow.cxx
index f4260cb..07ca615 100644
--- a/sc/source/ui/vba/vbawindow.cxx
+++ b/sc/source/ui/vba/vbawindow.cxx
@@ -126,7 +126,7 @@ public:
sheets.reserve( nTabCount );
uno::Reference <sheet::XSpreadsheetDocument> xSpreadSheet( m_xModel, uno::UNO_QUERY_THROW );
uno::Reference <container::XIndexAccess> xIndex( xSpreadSheet->getSheets(), uno::UNO_QUERY_THROW );
- ScMarkData::iterator itr = rMarkData.begin(), itrEnd = rMarkData.end();
+ ScMarkData::const_iterator itr = rMarkData.begin(), itrEnd = rMarkData.end();
for (; itr != itrEnd && *itr < nTabCount; ++itr)
{
uno::Reference< sheet::XSpreadsheet > xSheet( xIndex->getByIndex( *itr ), uno::UNO_QUERY_THROW );
diff --git a/sc/source/ui/view/pfuncache.cxx b/sc/source/ui/view/pfuncache.cxx
index 3ae227a..07d857e 100644
--- a/sc/source/ui/view/pfuncache.cxx
+++ b/sc/source/ui/view/pfuncache.cxx
@@ -111,7 +111,7 @@ void ScPrintFuncCache::InitLocations( const ScMarkData& rMark, OutputDevice* pDe
ScDocument* pDoc = pDocSh->GetDocument();
SCTAB nTabCount = pDoc->GetTableCount();
- ScMarkData::iterator itr = rMark.begin(), itrEnd = rMark.end();
+ ScMarkData::const_iterator itr = rMark.begin(), itrEnd = rMark.end();
for (; itr != itrEnd && (*itr) < nTabCount; ++itr)
{
SCTAB nTab = *itr;
diff --git a/sc/source/ui/view/tabvwshf.cxx b/sc/source/ui/view/tabvwshf.cxx
index b5ccdf0..2b5bd57 100644
--- a/sc/source/ui/view/tabvwshf.cxx
+++ b/sc/source/ui/view/tabvwshf.cxx
@@ -672,7 +672,7 @@ void ScTabViewShell::ExecuteTable( SfxRequest& rReq )
String aUndo = ScGlobal::GetRscString( STR_UNDO_TAB_RTL );
pUndoManager->EnterListAction( aUndo, aUndo );
- ScMarkData::iterator itr = rMark.begin(), itrEnd = rMark.end();
+ ScMarkData::const_iterator itr = rMark.begin(), itrEnd = rMark.end();
for (; itr != itrEnd; ++itr)
aFunc.SetLayoutRTL( *itr, bSet, false );
diff --git a/sc/source/ui/view/viewfun2.cxx b/sc/source/ui/view/viewfun2.cxx
index 7fce7b5..3144038 100644
--- a/sc/source/ui/view/viewfun2.cxx
+++ b/sc/source/ui/view/viewfun2.cxx
@@ -1233,7 +1233,7 @@ sal_Bool ScViewFunc::RemoveMerge( sal_Bool bRecord )
do
{
bExtended = false;
- ScMarkData::iterator itr = rMark.begin(), itrEnd = rMark.end();
+ ScMarkData::const_iterator itr = rMark.begin(), itrEnd = rMark.end();
for (; itr != itrEnd; ++itr)
{
SCTAB i = *itr;
diff --git a/sc/source/ui/view/viewfun3.cxx b/sc/source/ui/view/viewfun3.cxx
index 9b5a351..1853ab2 100644
--- a/sc/source/ui/view/viewfun3.cxx
+++ b/sc/source/ui/view/viewfun3.cxx
@@ -924,7 +924,7 @@ sal_Bool ScViewFunc::PasteOnDrawObject( const uno::Reference<datatransfer::XTran
sal_Bool lcl_SelHasAttrib( ScDocument* pDoc, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2,
const ScMarkData& rTabSelection, sal_uInt16 nMask )
{
- ScMarkData::iterator itr = rTabSelection.begin(), itrEnd = rTabSelection.end();
+ ScMarkData::const_iterator itr = rTabSelection.begin(), itrEnd = rTabSelection.end();
for (; itr != itrEnd; ++itr)
if ( pDoc->HasAttrib( nCol1, nRow1, *itr, nCol2, nRow2, *itr, nMask ) )
return sal_True;
@@ -959,7 +959,7 @@ private:
bool lcl_checkDestRangeForOverwrite(const ScRange& rDestRange, const ScDocument* pDoc, const ScMarkData& rMark, Window* pParentWnd)
{
bool bIsEmpty = true;
- ScMarkData::iterator itr = rMark.begin(), itrEnd = rMark.end();
+ ScMarkData::const_iterator itr = rMark.begin(), itrEnd = rMark.end();
for (; itr != itrEnd && bIsEmpty; ++itr)
{
bIsEmpty = pDoc->IsBlockEmpty(*itr, rDestRange.aStart.Col(), rDestRange.aStart.Row(),
@@ -1738,7 +1738,7 @@ void ScViewFunc::PostPasteFromClip(const ScRange& rPasteRange, const ScMarkData&
if ( pModelObj && pModelObj->HasChangesListeners() )
{
ScRangeList aChangeRanges;
- ScMarkData::iterator itr = rMark.begin(), itrEnd = rMark.end();
+ ScMarkData::const_iterator itr = rMark.begin(), itrEnd = rMark.end();
for (; itr != itrEnd; ++itr)
{
ScRange aChangeRange(rPasteRange);
More information about the Libreoffice-commits
mailing list