summaryrefslogtreecommitdiff
path: root/sd
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2015-05-29 13:34:26 +0200
committerNoel Grandin <noel@peralex.com>2015-06-02 09:45:16 +0200
commit1df41142451685d33b1821a839061c63f23e44fd (patch)
treebe78d70c5212ffb3496bf9fb6ec5f75f4c5e649c /sd
parent44cab3c9db5aef97fde57baec205a34fc794f64b (diff)
loplugin:loopvartoosmall
Change-Id: I809e408c994222cfa95ba8f56e4db7bd96be7080
Diffstat (limited to 'sd')
-rw-r--r--sd/source/core/EffectMigration.cxx2
-rw-r--r--sd/source/ui/accessibility/AccessibleDocumentViewBase.cxx2
-rw-r--r--sd/source/ui/framework/configuration/Configuration.cxx2
-rw-r--r--sd/source/ui/sidebar/LayoutMenu.cxx2
-rw-r--r--sd/source/ui/sidebar/MasterPagesSelector.cxx6
-rw-r--r--sd/source/ui/slideshow/slideshowimpl.cxx2
-rw-r--r--sd/source/ui/slidesorter/controller/SlsClipboard.cxx2
-rw-r--r--sd/source/ui/slidesorter/view/SlideSorterView.cxx4
-rw-r--r--sd/source/ui/slidesorter/view/SlsFramePainter.cxx4
-rw-r--r--sd/source/ui/slidesorter/view/SlsInsertionIndicatorOverlay.cxx4
-rw-r--r--sd/source/ui/slidesorter/view/SlsLayeredDevice.cxx4
-rw-r--r--sd/source/ui/slidesorter/view/SlsPageObjectPainter.cxx4
-rw-r--r--sd/source/ui/tools/ConfigurationAccess.cxx2
-rw-r--r--sd/source/ui/unoidl/DrawController.cxx2
-rw-r--r--sd/source/ui/view/ViewTabBar.cxx4
-rw-r--r--sd/source/ui/view/drviews5.cxx2
-rw-r--r--sd/source/ui/view/frmview.cxx2
-rw-r--r--sd/source/ui/view/outlview.cxx2
-rw-r--r--sd/source/ui/view/sdview3.cxx2
19 files changed, 27 insertions, 27 deletions
diff --git a/sd/source/core/EffectMigration.cxx b/sd/source/core/EffectMigration.cxx
index 855cb9fad204..cc5c20c74857 100644
--- a/sd/source/core/EffectMigration.cxx
+++ b/sd/source/core/EffectMigration.cxx
@@ -1406,7 +1406,7 @@ void EffectMigration::CreateAnimatedGroup(SdrObjGroup& rGroupObj, SdPage& rPage)
const double fDurationShow(0.2);
const double fDurationHide(0.001);
- for(sal_uInt32 a(0); a < aObjects.size(); a++)
+ for(size_t a(0); a < aObjects.size(); a++)
{
SdrObject* pLast = pNext;
pNext = aObjects[a];
diff --git a/sd/source/ui/accessibility/AccessibleDocumentViewBase.cxx b/sd/source/ui/accessibility/AccessibleDocumentViewBase.cxx
index a1f7fca04035..6c080b8178b2 100644
--- a/sd/source/ui/accessibility/AccessibleDocumentViewBase.cxx
+++ b/sd/source/ui/accessibility/AccessibleDocumentViewBase.cxx
@@ -816,7 +816,7 @@ uno::Any SAL_CALL AccessibleDocumentViewBase::getExtendedAttributes()
{
sValue += "note:";
const EditTextObject& rEdit = pPara->GetTextObject();
- for (sal_uInt16 i=0;i<rEdit.GetParagraphCount();i++)
+ for (sal_Int32 i=0;i<rEdit.GetParagraphCount();i++)
{
OUString strNote = rEdit.GetText(i);
strNote = strNote.replaceFirst( "\\", "\\\\" );
diff --git a/sd/source/ui/framework/configuration/Configuration.cxx b/sd/source/ui/framework/configuration/Configuration.cxx
index f64bcd5f9346..82878ed9509a 100644
--- a/sd/source/ui/framework/configuration/Configuration.cxx
+++ b/sd/source/ui/framework/configuration/Configuration.cxx
@@ -170,7 +170,7 @@ Sequence<Reference<XResourceId> > SAL_CALL Configuration::getResources (
// Copy the resources from the vector into a new sequence.
Sequence<Reference<XResourceId> > aResult (aResources.size());
- for (sal_uInt32 nIndex=0; nIndex<aResources.size(); ++nIndex)
+ for (size_t nIndex=0; nIndex<aResources.size(); ++nIndex)
aResult[nIndex] = aResources[nIndex];
return aResult;
diff --git a/sd/source/ui/sidebar/LayoutMenu.cxx b/sd/source/ui/sidebar/LayoutMenu.cxx
index dd440ad449fc..0d731a5458ed 100644
--- a/sd/source/ui/sidebar/LayoutMenu.cxx
+++ b/sd/source/ui/sidebar/LayoutMenu.cxx
@@ -567,7 +567,7 @@ void LayoutMenu::Fill()
void LayoutMenu::Clear()
{
- for (sal_uInt16 nId=1; nId<=GetItemCount(); nId++)
+ for (size_t nId=1; nId<=GetItemCount(); nId++)
delete static_cast<AutoLayout*>(GetItemData(nId));
ValueSet::Clear();
}
diff --git a/sd/source/ui/sidebar/MasterPagesSelector.cxx b/sd/source/ui/sidebar/MasterPagesSelector.cxx
index 0ac4680fbf5d..2dcf5c278d86 100644
--- a/sd/source/ui/sidebar/MasterPagesSelector.cxx
+++ b/sd/source/ui/sidebar/MasterPagesSelector.cxx
@@ -573,7 +573,7 @@ void MasterPagesSelector::InvalidatePreview (const SdPage* pPage)
{
const ::osl::MutexGuard aGuard (maMutex);
- for (sal_uInt16 nIndex=1; nIndex<=PreviewValueSet::GetItemCount(); nIndex++)
+ for (size_t nIndex=1; nIndex<=PreviewValueSet::GetItemCount(); nIndex++)
{
UserData* pData = GetUserData(nIndex);
if (pData != NULL)
@@ -593,7 +593,7 @@ void MasterPagesSelector::UpdateAllPreviews()
{
const ::osl::MutexGuard aGuard (maMutex);
- for (sal_uInt16 nIndex=1; nIndex<=PreviewValueSet::GetItemCount(); nIndex++)
+ for (size_t nIndex=1; nIndex<=PreviewValueSet::GetItemCount(); nIndex++)
{
UserData* pData = GetUserData(nIndex);
if (pData != NULL)
@@ -613,7 +613,7 @@ void MasterPagesSelector::ClearPageSet()
{
const ::osl::MutexGuard aGuard (maMutex);
- for (sal_uInt16 nIndex=1; nIndex<=PreviewValueSet::GetItemCount(); nIndex++)
+ for (size_t nIndex=1; nIndex<=PreviewValueSet::GetItemCount(); nIndex++)
{
UserData* pData = GetUserData(nIndex);
if (pData != NULL)
diff --git a/sd/source/ui/slideshow/slideshowimpl.cxx b/sd/source/ui/slideshow/slideshowimpl.cxx
index adce12becdba..dfc7a998d262 100644
--- a/sd/source/ui/slideshow/slideshowimpl.cxx
+++ b/sd/source/ui/slideshow/slideshowimpl.cxx
@@ -2406,7 +2406,7 @@ Reference< XSlideShow > SlideshowImpl::createSlideShow()
void SlideshowImpl::createSlideList( bool bAll, const OUString& rPresSlide )
{
- const long nSlideCount = mpDoc->GetSdPageCount( PK_STANDARD );
+ const sal_uInt16 nSlideCount = mpDoc->GetSdPageCount( PK_STANDARD );
if( nSlideCount )
{
diff --git a/sd/source/ui/slidesorter/controller/SlsClipboard.cxx b/sd/source/ui/slidesorter/controller/SlsClipboard.cxx
index 7dfc356a77b1..6511aa06909c 100644
--- a/sd/source/ui/slidesorter/controller/SlsClipboard.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsClipboard.cxx
@@ -360,7 +360,7 @@ void Clipboard::SelectPageRange (sal_Int32 nFirstIndex, sal_Int32 nPageCount)
// after the nInsertIndex position.
PageSelector& rSelector (mrController.GetPageSelector());
rSelector.DeselectAllPages();
- for (sal_uInt16 i=0; i<nPageCount; i++)
+ for (sal_Int32 i=0; i<nPageCount; i++)
{
model::SharedPageDescriptor pDescriptor (
mrSlideSorter.GetModel().GetPageDescriptor(nFirstIndex + i));
diff --git a/sd/source/ui/slidesorter/view/SlideSorterView.cxx b/sd/source/ui/slidesorter/view/SlideSorterView.cxx
index c1428c874c59..1661844100c8 100644
--- a/sd/source/ui/slidesorter/view/SlideSorterView.cxx
+++ b/sd/source/ui/slidesorter/view/SlideSorterView.cxx
@@ -469,7 +469,7 @@ void SlideSorterView::DeterminePageObjectVisibilities()
mbPreciousFlagUpdatePending |= true;
model::SharedPageDescriptor pDescriptor;
- for (int nIndex=aUnion.Min(); nIndex<=aUnion.Max(); nIndex++)
+ for (long nIndex=aUnion.Min(); nIndex<=aUnion.Max(); nIndex++)
{
pDescriptor = mrModel.GetPageDescriptor(nIndex);
if (pDescriptor.get() != NULL)
@@ -675,7 +675,7 @@ void SlideSorterView::Paint (
// Paint all page objects that are fully or partially inside the
// repaint region.
const Range aRange (mpLayouter->GetRangeOfVisiblePageObjects(rRepaintArea));
- for (sal_Int32 nIndex=aRange.Min(); nIndex<=aRange.Max(); ++nIndex)
+ for (long nIndex=aRange.Min(); nIndex<=aRange.Max(); ++nIndex)
{
model::SharedPageDescriptor pDescriptor (mrModel.GetPageDescriptor(nIndex));
if (!pDescriptor || ! pDescriptor->HasState(PageDescriptor::ST_Visible))
diff --git a/sd/source/ui/slidesorter/view/SlsFramePainter.cxx b/sd/source/ui/slidesorter/view/SlsFramePainter.cxx
index dd0c03fcdcfc..f89330eee447 100644
--- a/sd/source/ui/slidesorter/view/SlsFramePainter.cxx
+++ b/sd/source/ui/slidesorter/view/SlsFramePainter.cxx
@@ -218,8 +218,8 @@ void FramePainter::OffsetBitmap::PaintCenter (
const Rectangle& rBox) const
{
const Size aBitmapSize (maBitmap.GetSizePixel());
- for (sal_Int32 nY=rBox.Top(); nY<=rBox.Bottom(); nY+=aBitmapSize.Height())
- for (sal_Int32 nX=rBox.Left(); nX<=rBox.Right(); nX+=aBitmapSize.Width())
+ for (long nY=rBox.Top(); nY<=rBox.Bottom(); nY+=aBitmapSize.Height())
+ for (long nX=rBox.Left(); nX<=rBox.Right(); nX+=aBitmapSize.Width())
rDevice.DrawBitmapEx(
Point(nX,nY),
Size(
diff --git a/sd/source/ui/slidesorter/view/SlsInsertionIndicatorOverlay.cxx b/sd/source/ui/slidesorter/view/SlsInsertionIndicatorOverlay.cxx
index cb237454d009..d10615fc3b86 100644
--- a/sd/source/ui/slidesorter/view/SlsInsertionIndicatorOverlay.cxx
+++ b/sd/source/ui/slidesorter/view/SlsInsertionIndicatorOverlay.cxx
@@ -199,8 +199,8 @@ Point InsertionIndicatorOverlay::PaintRepresentatives (
const sal_Int32 nIconHeight (aExclusionOverlay.GetSizePixel().Height());
if (nIconWidth>0 && nIconHeight>0)
{
- for (sal_Int32 nX=0; nX<rPreviewSize.Width(); nX+=nIconWidth)
- for (sal_Int32 nY=0; nY<rPreviewSize.Height(); nY+=nIconHeight)
+ for (long nX=0; nX<rPreviewSize.Width(); nX+=nIconWidth)
+ for (long nY=0; nY<rPreviewSize.Height(); nY+=nIconHeight)
rContent.DrawBitmapEx(Point(nX,nY)+aPageOffset, aExclusionOverlay);
}
rContent.SetClipRegion(aSavedClipRegion);
diff --git a/sd/source/ui/slidesorter/view/SlsLayeredDevice.cxx b/sd/source/ui/slidesorter/view/SlsLayeredDevice.cxx
index d22f5cf801ac..72cecd66c482 100644
--- a/sd/source/ui/slidesorter/view/SlsLayeredDevice.cxx
+++ b/sd/source/ui/slidesorter/view/SlsLayeredDevice.cxx
@@ -187,13 +187,13 @@ void LayeredDevice::Invalidate (
void LayeredDevice::InvalidateAllLayers (const Rectangle& rInvalidationArea)
{
- for (sal_uInt32 nLayer=0; nLayer<mpLayers->size(); ++nLayer)
+ for (size_t nLayer=0; nLayer<mpLayers->size(); ++nLayer)
(*mpLayers)[nLayer]->InvalidateRectangle(rInvalidationArea);
}
void LayeredDevice::InvalidateAllLayers (const vcl::Region& rInvalidationRegion)
{
- for (sal_uInt32 nLayer=0; nLayer<mpLayers->size(); ++nLayer)
+ for (size_t nLayer=0; nLayer<mpLayers->size(); ++nLayer)
(*mpLayers)[nLayer]->InvalidateRegion(rInvalidationRegion);
}
diff --git a/sd/source/ui/slidesorter/view/SlsPageObjectPainter.cxx b/sd/source/ui/slidesorter/view/SlsPageObjectPainter.cxx
index 79eea5518bc7..91b7e8ef3346 100644
--- a/sd/source/ui/slidesorter/view/SlsPageObjectPainter.cxx
+++ b/sd/source/ui/slidesorter/view/SlsPageObjectPainter.cxx
@@ -174,8 +174,8 @@ Bitmap PageObjectPainter::CreateMarkedPreview (
const sal_Int32 nIconHeight (rOverlay.GetSizePixel().Height());
if (nIconWidth>0 && nIconHeight>0)
{
- for (sal_Int32 nX=0; nX<rSize.Width(); nX+=nIconWidth)
- for (sal_Int32 nY=0; nY<rSize.Height(); nY+=nIconHeight)
+ for (long nX=0; nX<rSize.Width(); nX+=nIconWidth)
+ for (long nY=0; nY<rSize.Height(); nY+=nIconHeight)
pDevice->DrawBitmapEx(Point(nX,nY), rOverlay);
}
return pDevice->GetBitmap(Point(0,0), rSize);
diff --git a/sd/source/ui/tools/ConfigurationAccess.cxx b/sd/source/ui/tools/ConfigurationAccess.cxx
index 565a152e3135..29c237bf01b8 100644
--- a/sd/source/ui/tools/ConfigurationAccess.cxx
+++ b/sd/source/ui/tools/ConfigurationAccess.cxx
@@ -147,7 +147,7 @@ void ConfigurationAccess::ForAll (
{
// Get from the current item of the container the children
// that match the names in the rArguments list.
- for (sal_uInt32 nValueIndex=0; nValueIndex<aValues.size(); ++nValueIndex)
+ for (size_t nValueIndex=0; nValueIndex<aValues.size(); ++nValueIndex)
aValues[nValueIndex] = xSetItem->getByName(rArguments[nValueIndex]);
}
rFunctor(rsKey, aValues);
diff --git a/sd/source/ui/unoidl/DrawController.cxx b/sd/source/ui/unoidl/DrawController.cxx
index e12a15bc75c6..fed8f315d8c9 100644
--- a/sd/source/ui/unoidl/DrawController.cxx
+++ b/sd/source/ui/unoidl/DrawController.cxx
@@ -684,7 +684,7 @@ IPropertyArrayHelper & DrawController::getInfoHelper()
::std::vector<beans::Property> aProperties;
FillPropertyTable (aProperties);
Sequence<beans::Property> aPropertySequence (aProperties.size());
- for (unsigned int i=0; i<aProperties.size(); i++)
+ for (size_t i=0; i<aProperties.size(); i++)
aPropertySequence[i] = aProperties[i];
mpPropertyArrayHelper.reset(new OPropertyArrayHelper(aPropertySequence, sal_False));
}
diff --git a/sd/source/ui/view/ViewTabBar.cxx b/sd/source/ui/view/ViewTabBar.cxx
index c32b92ff43ae..181fa15a2c5e 100644
--- a/sd/source/ui/view/ViewTabBar.cxx
+++ b/sd/source/ui/view/ViewTabBar.cxx
@@ -483,7 +483,7 @@ bool ViewTabBar::HasTabBarButton (
{
bool bResult (false);
- for (sal_uInt32 nIndex=0; nIndex<maTabBarButtons.size(); ++nIndex)
+ for (size_t nIndex=0; nIndex<maTabBarButtons.size(); ++nIndex)
{
if (IsEqual(maTabBarButtons[nIndex], rButton))
{
@@ -517,7 +517,7 @@ void ViewTabBar::UpdateActiveButton()
if (xView.is())
{
Reference<XResourceId> xViewId (xView->getResourceId());
- for (sal_uInt16 nIndex=0; nIndex<maTabBarButtons.size(); ++nIndex)
+ for (size_t nIndex=0; nIndex<maTabBarButtons.size(); ++nIndex)
{
if (maTabBarButtons[nIndex].ResourceId->compareTo(xViewId) == 0)
{
diff --git a/sd/source/ui/view/drviews5.cxx b/sd/source/ui/view/drviews5.cxx
index 030c676bc3db..1c34b1797583 100644
--- a/sd/source/ui/view/drviews5.cxx
+++ b/sd/source/ui/view/drviews5.cxx
@@ -466,7 +466,7 @@ void DrawViewShell::ReadUserDataSequence ( const ::com::sun::star::uno::Sequence
const sal_Int32 nLength = rSequence.getLength();
const com::sun::star::beans::PropertyValue *pValue = rSequence.getConstArray();
- for (sal_Int16 i = 0 ; i < nLength; i++, pValue++ )
+ for (sal_Int32 i = 0 ; i < nLength; i++, pValue++ )
{
if ( pValue->Name == sUNO_View_ZoomOnPage )
{
diff --git a/sd/source/ui/view/frmview.cxx b/sd/source/ui/view/frmview.cxx
index 329fa9cff449..fe12af267d53 100644
--- a/sd/source/ui/view/frmview.cxx
+++ b/sd/source/ui/view/frmview.cxx
@@ -566,7 +566,7 @@ void FrameView::ReadUserDataSequence ( const ::com::sun::star::uno::Sequence < :
sal_Int32 aSnapGridWidthYDom = GetSnapGridWidthY().GetDenominator();
const com::sun::star::beans::PropertyValue *pValue = rSequence.getConstArray();
- for (sal_Int16 i = 0 ; i < nLength; i++, pValue++ )
+ for (sal_Int32 i = 0 ; i < nLength; i++, pValue++ )
{
if ( pValue->Name == sUNO_View_ViewId )
{
diff --git a/sd/source/ui/view/outlview.cxx b/sd/source/ui/view/outlview.cxx
index 277d262fc163..455640e1a0e1 100644
--- a/sd/source/ui/view/outlview.cxx
+++ b/sd/source/ui/view/outlview.cxx
@@ -1086,7 +1086,7 @@ void OutlineView::FillOutliner()
mrOutliner.SetUpdateMode(false);
Paragraph* pTitleToSelect = NULL;
- sal_uLong nPageCount = mrDoc.GetSdPageCount(PK_STANDARD);
+ sal_uInt16 nPageCount = mrDoc.GetSdPageCount(PK_STANDARD);
// fill outliner with paragraphs from slides title & (outlines|subtitles)
for (sal_uInt16 nPage = 0; nPage < nPageCount; nPage++)
diff --git a/sd/source/ui/view/sdview3.cxx b/sd/source/ui/view/sdview3.cxx
index a02ec4e709bd..f0dd92267b69 100644
--- a/sd/source/ui/view/sdview3.cxx
+++ b/sd/source/ui/view/sdview3.cxx
@@ -105,7 +105,7 @@ struct ImpRememberOrigAndClone
SdrObject* ImpGetClone(std::vector<ImpRememberOrigAndClone*>& aConnectorContainer, SdrObject* pConnObj)
{
- for(sal_uInt32 a(0); a < aConnectorContainer.size(); a++)
+ for(size_t a(0); a < aConnectorContainer.size(); a++)
{
if(pConnObj == aConnectorContainer[a]->pOrig)
return aConnectorContainer[a]->pClone;