summaryrefslogtreecommitdiff
path: root/fpicker/source/office
diff options
context:
space:
mode:
authorMichael Meeks <michael.meeks@suse.com>2012-05-29 17:23:51 +0100
committerMichael Meeks <michael.meeks@suse.com>2012-05-29 18:03:34 +0100
commit6e6d81e9cfc593d865e409ad22b2307f87a37859 (patch)
tree4d578e5be2dfd3a403576d7c638f83f041d56911 /fpicker/source/office
parentb7c6716b4bc0742af4206035495d161e7eb49424 (diff)
targetted SAL_N_ELEMENTS reversion.
Change-Id: I30be93ccaeb1f9fd17cbe9e3ed3165e094810b2e
Diffstat (limited to 'fpicker/source/office')
-rw-r--r--fpicker/source/office/OfficeControlAccess.cxx4
-rw-r--r--fpicker/source/office/iodlg.cxx10
2 files changed, 7 insertions, 7 deletions
diff --git a/fpicker/source/office/OfficeControlAccess.cxx b/fpicker/source/office/OfficeControlAccess.cxx
index 21bcf83daa0c..05ebab7c27c3 100644
--- a/fpicker/source/office/OfficeControlAccess.cxx
+++ b/fpicker/source/office/OfficeControlAccess.cxx
@@ -116,7 +116,7 @@ namespace svt
};
// ................................................................
- static const sal_Int32 s_nControlCount = SAL_N_ELEMENTS( aDescriptions );
+ static const sal_Int32 s_nControlCount = sizeof( aDescriptions ) / sizeof( aDescriptions[0] );
static ControlDescIterator s_pControls = aDescriptions;
static ControlDescIterator s_pControlsEnd = aDescriptions + s_nControlCount;
@@ -162,7 +162,7 @@ namespace svt
};
// ................................................................
- static const int s_nPropertyCount = SAL_N_ELEMENTS( aProperties );
+ static const int s_nPropertyCount = sizeof( aProperties ) / sizeof( aProperties[0] );
static ControlPropertyIterator s_pProperties = aProperties;
static ControlPropertyIterator s_pPropertiesEnd = aProperties + s_nPropertyCount;
diff --git a/fpicker/source/office/iodlg.cxx b/fpicker/source/office/iodlg.cxx
index 4de4a0c0bfb8..3209ad6bccf3 100644
--- a/fpicker/source/office/iodlg.cxx
+++ b/fpicker/source/office/iodlg.cxx
@@ -2526,7 +2526,7 @@ void SvtFileDialog::implArrangeControls()
// loop through all these controls and adjust the z-order
Window* pPreviousWin = NULL;
Control** pCurrent = pControls;
- for ( sal_Int32 i = 0; i < sal_Int32(SAL_N_ELEMENTS( pControls )); ++i, ++pCurrent )
+ for ( sal_Int32 i = 0; i < sal_Int32(sizeof( pControls ) / sizeof( pControls[ 0 ] )); ++i, ++pCurrent )
{
if ( !*pCurrent )
// this control is not available in the current operation mode -> skip
@@ -2697,7 +2697,7 @@ void SvtFileDialog::Resize()
_pImp->_pBtnAddPlace, _pImp->_pBtnRemovePlace
};
Control** ppMoveControls = aMoveControlsVert;
- Control** ppMoveControlsEnd = ppMoveControls + SAL_N_ELEMENTS( aMoveControlsVert );
+ Control** ppMoveControlsEnd = ppMoveControls + sizeof( aMoveControlsVert ) / sizeof( aMoveControlsVert[0] );
for ( ; ppMoveControls != ppMoveControlsEnd; ++ppMoveControls )
lcl_MoveControl( *ppMoveControls, 0, nDeltaY );
}
@@ -2709,7 +2709,7 @@ void SvtFileDialog::Resize()
_pImp->_pBtnFileOpen, _pImp->_pBtnCancel, _pImp->_pBtnHelp
};
Control** ppMoveControls = aMoveControlsBoth;
- Control** ppMoveControlsEnd = ppMoveControls + SAL_N_ELEMENTS( aMoveControlsBoth );
+ Control** ppMoveControlsEnd = ppMoveControls + sizeof( aMoveControlsBoth ) / sizeof( aMoveControlsBoth[0] );
for ( ; ppMoveControls != ppMoveControlsEnd; ++ppMoveControls )
lcl_MoveControl( *ppMoveControls, nDeltaX, nDeltaY );
}
@@ -2722,7 +2722,7 @@ void SvtFileDialog::Resize()
_pImp->_pBtnUp, _pImp->_pBtnNewFolder
};
Control** ppMoveControls = aMoveControlsHor;
- Control** ppMoveControlsEnd = ppMoveControls + SAL_N_ELEMENTS( aMoveControlsHor );
+ Control** ppMoveControlsEnd = ppMoveControls + sizeof( aMoveControlsHor ) / sizeof( aMoveControlsHor[0] );
for ( ; ppMoveControls != ppMoveControlsEnd; ++ppMoveControls )
lcl_MoveControl( *ppMoveControls, nDeltaX, 0 );
}
@@ -2735,7 +2735,7 @@ void SvtFileDialog::Resize()
_pImp->_pEdFileName, _pImp->_pLbFileVersion, _pImp->_pLbTemplates, _pImp->_pLbImageTemplates,
_pImp->GetFilterListControl(), _pImp->_pEdCurrentPath,
};
- sal_Int32 nSizeControls = SAL_N_ELEMENTS( aSizeControls );
+ sal_Int32 nSizeControls = sizeof( aSizeControls ) / sizeof( aSizeControls[0] );
Control** ppSizeControls = aSizeControls;
for ( sal_Int32 j=0; j<nSizeControls; ++j, ++ppSizeControls )
{