From f7a24eff2d40ca30c6f299ab6534393c5c146b95 Mon Sep 17 00:00:00 2001 From: Luboš Luňák Date: Fri, 12 Oct 2012 13:26:46 +0200 Subject: mark lcl_ functions static or rename them if they are not local at all http://lists.freedesktop.org/archives/libreoffice/2012-October/039639.html Change-Id: I231f0b367bf0b513c6c1ce4c4cfdb7c3dc8660d5 --- editeng/source/editeng/editundo.cxx | 2 +- editeng/source/editeng/impedit.cxx | 2 +- editeng/source/editeng/impedit2.cxx | 2 +- editeng/source/editeng/impedit3.cxx | 4 ++-- editeng/source/editeng/impedit4.cxx | 2 +- editeng/source/items/frmitems.cxx | 4 ++-- editeng/source/items/numitem.cxx | 2 +- editeng/source/items/textitem.cxx | 2 +- editeng/source/rtf/svxrtf.cxx | 2 +- 9 files changed, 11 insertions(+), 11 deletions(-) (limited to 'editeng/source') diff --git a/editeng/source/editeng/editundo.cxx b/editeng/source/editeng/editundo.cxx index ac5a6de2cb69..3448e0290913 100644 --- a/editeng/source/editeng/editundo.cxx +++ b/editeng/source/editeng/editundo.cxx @@ -40,7 +40,7 @@ DBG_NAME( EditUndo ) #define NO_UNDO 0xFFFF #define GROUP_NOTFOUND 0xFFFF -void lcl_DoSetSelection( EditView* pView, sal_uInt16 nPara ) +static void lcl_DoSetSelection( EditView* pView, sal_uInt16 nPara ) { EPaM aEPaM( nPara, 0 ); EditPaM aPaM( pView->GetImpEditEngine()->CreateEditPaM( aEPaM ) ); diff --git a/editeng/source/editeng/impedit.cxx b/editeng/source/editeng/impedit.cxx index e63014eb526f..9da932320f15 100644 --- a/editeng/source/editeng/impedit.cxx +++ b/editeng/source/editeng/impedit.cxx @@ -60,7 +60,7 @@ using namespace ::com::sun::star::linguistic2; #define SCRLRANGE 20 // Scroll 1/20 of the width/height, when in QueryDrop -inline void lcl_AllignToPixel( Point& rPoint, OutputDevice* pOutDev, short nDiffX, short nDiffY ) +static inline void lcl_AllignToPixel( Point& rPoint, OutputDevice* pOutDev, short nDiffX, short nDiffY ) { rPoint = pOutDev->LogicToPixel( rPoint ); diff --git a/editeng/source/editeng/impedit2.cxx b/editeng/source/editeng/impedit2.cxx index 3c9990e9d199..0249020c0374 100644 --- a/editeng/source/editeng/impedit2.cxx +++ b/editeng/source/editeng/impedit2.cxx @@ -77,7 +77,7 @@ using namespace ::com::sun::star; -sal_uInt16 lcl_CalcExtraSpace( ParaPortion*, const SvxLineSpacingItem& rLSItem ) +static sal_uInt16 lcl_CalcExtraSpace( ParaPortion*, const SvxLineSpacingItem& rLSItem ) { sal_uInt16 nExtra = 0; if ( rLSItem.GetInterLineSpaceRule() == SVX_INTER_LINE_SPACE_FIX ) diff --git a/editeng/source/editeng/impedit3.cxx b/editeng/source/editeng/impedit3.cxx index 79edb1ebde9e..5878822991db 100644 --- a/editeng/source/editeng/impedit3.cxx +++ b/editeng/source/editeng/impedit3.cxx @@ -152,7 +152,7 @@ sal_uInt8 GetCharTypeForCompression( xub_Unicode cChar ) } } -void lcl_DrawRedLines( +static void lcl_DrawRedLines( OutputDevice* pOutDev, long nFontHeight, const Point& rPnt, @@ -238,7 +238,7 @@ void lcl_DrawRedLines( } } -Point lcl_ImplCalcRotatedPos( Point rPos, Point rOrigin, double nSin, double nCos ) +static Point lcl_ImplCalcRotatedPos( Point rPos, Point rOrigin, double nSin, double nCos ) { Point aRotatedPos; // Translation... diff --git a/editeng/source/editeng/impedit4.cxx b/editeng/source/editeng/impedit4.cxx index f5306703ebca..d6ff77ff698c 100644 --- a/editeng/source/editeng/impedit4.cxx +++ b/editeng/source/editeng/impedit4.cxx @@ -290,7 +290,7 @@ sal_Bool ImpEditEngine::WriteItemListAsRTF( ItemList& rLst, SvStream& rOutput, s return ( rLst.Count() ? sal_True : sal_False ); } -void lcl_FindValidAttribs( ItemList& rLst, ContentNode* pNode, sal_uInt16 nIndex, sal_uInt16 nScriptType ) +static void lcl_FindValidAttribs( ItemList& rLst, ContentNode* pNode, sal_uInt16 nIndex, sal_uInt16 nScriptType ) { sal_uInt16 nAttr = 0; EditCharAttrib* pAttr = GetAttrib( pNode->GetCharAttribs().GetAttribs(), nAttr ); diff --git a/editeng/source/items/frmitems.cxx b/editeng/source/items/frmitems.cxx index 0cd31ad5274e..cd903fec09f5 100644 --- a/editeng/source/items/frmitems.cxx +++ b/editeng/source/items/frmitems.cxx @@ -3588,12 +3588,12 @@ sal_uInt16 SvxBrushItem::GetVersion( sal_uInt16 /*nFileVersion*/ ) const } // ----------------------------------------------------------------------- -inline sal_Int8 lcl_PercentToTransparency(long nPercent) +static inline sal_Int8 lcl_PercentToTransparency(long nPercent) { //0xff must not be returned! return sal_Int8(nPercent ? (50 + 0xfe * nPercent) / 100 : 0); } -inline sal_Int8 lcl_TransparencyToPercent(sal_Int32 nTrans) +static inline sal_Int8 lcl_TransparencyToPercent(sal_Int32 nTrans) { return (sal_Int8)((nTrans * 100 + 127) / 254); } diff --git a/editeng/source/items/numitem.cxx b/editeng/source/items/numitem.cxx index 039d3e483557..e01981528b26 100644 --- a/editeng/source/items/numitem.cxx +++ b/editeng/source/items/numitem.cxx @@ -70,7 +70,7 @@ using namespace ::com::sun::star::style; sal_Int32 SvxNumberType::nRefCount = 0; com::sun::star::uno::Reference SvxNumberType::xFormatter = 0; -void lcl_getFormatter(com::sun::star::uno::Reference& _xFormatter) +static void lcl_getFormatter(com::sun::star::uno::Reference& _xFormatter) { if(!_xFormatter.is()) { diff --git a/editeng/source/items/textitem.cxx b/editeng/source/items/textitem.cxx index 41ea8a683838..70ae5fe5eac9 100644 --- a/editeng/source/items/textitem.cxx +++ b/editeng/source/items/textitem.cxx @@ -932,7 +932,7 @@ bool SvxFontHeightItem::QueryValue( uno::Any& rVal, sal_uInt8 nMemberId ) const } // Calculate the relative deviation from the expected height. -sal_uInt32 lcl_GetRealHeight_Impl(sal_uInt32 nHeight, sal_uInt16 nProp, SfxMapUnit eProp, sal_Bool bCoreInTwip) +static sal_uInt32 lcl_GetRealHeight_Impl(sal_uInt32 nHeight, sal_uInt16 nProp, SfxMapUnit eProp, sal_Bool bCoreInTwip) { sal_uInt32 nRet = nHeight; short nDiff = 0; diff --git a/editeng/source/rtf/svxrtf.cxx b/editeng/source/rtf/svxrtf.cxx index 2f727e3dddd5..986a65473c2d 100644 --- a/editeng/source/rtf/svxrtf.cxx +++ b/editeng/source/rtf/svxrtf.cxx @@ -51,7 +51,7 @@ using namespace ::com::sun::star; -CharSet lcl_GetDefaultTextEncodingForRTF() +static CharSet lcl_GetDefaultTextEncodingForRTF() { ::com::sun::star::lang::Locale aLocale; -- cgit