summaryrefslogtreecommitdiff
path: root/rsc
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2012-01-21 15:21:16 +0100
committerStephan Bergmann <sbergman@redhat.com>2012-01-21 15:21:16 +0100
commit7c704c78d3c652504c064b4ac7af55a2c1ee49bb (patch)
tree623358cf25839219ef4fd90eea4f3eaa55389a1f /rsc
parent0d5167915b47df7c3e450614ea50d845ba959df3 (diff)
Removed some unused parameters; added SAL_UNUSED_PARAMETER.
SAL_UNUSED_PARAMETER (expanding to __attribute__ ((unused)) for GCC) is used to annotate legitimately unused parameters, so that static analysis tools can tell legitimately unused parameters from truly unnecessary ones. To that end, some patches for external modules are also added, that are only applied when compiling with GCC and add necessary __attribute__ ((unused)) in headers.
Diffstat (limited to 'rsc')
-rw-r--r--rsc/inc/rscdb.hxx14
-rw-r--r--rsc/source/parser/rscdb.cxx2
-rw-r--r--rsc/source/parser/rscicpx.cxx16
-rw-r--r--rsc/source/parser/rscinit.cxx13
-rw-r--r--rsc/source/rsc/rsc.cxx5
5 files changed, 20 insertions, 30 deletions
diff --git a/rsc/inc/rscdb.hxx b/rsc/inc/rscdb.hxx
index c7a4950cbdd5..6b002ee14abf 100644
--- a/rsc/inc/rscdb.hxx
+++ b/rsc/inc/rscdb.hxx
@@ -177,7 +177,7 @@ class RscTypCont
RscTop * InitClassColor( RscTop * pSuper, RscEnum * pColor );
RscTop * InitClassImage( RscTop * pSuper, RscTop *pClassBitmap,
RscTop * pClassColor );
- RscTop * InitClassImageList( RscTop * pSuper, RscTop *pClassBitmap,
+ RscTop * InitClassImageList( RscTop * pSuper,
RscTop * pClassColor, RscCont * pStrLst );
RscTop * InitClassWindow( RscTop * pSuper, RscEnum * pMapUnit,
RscArray * pLangGeo );
@@ -221,8 +221,7 @@ class RscTypCont
RscTop * InitClassNumericFormatter( RscTop * pSuper );
RscTop * InitClassMetricFormatter( RscTop * pSuper,
RscEnum * pFieldUnits );
- RscTop * InitClassCurrencyFormatter( RscTop * pSuper,
- RscEnum * pFieldUnits );
+ RscTop * InitClassCurrencyFormatter( RscTop * pSuper );
RscTop * InitClassDateFormatter( RscTop * pSuper, RscTop * pClassDate );
RscTop * InitClassTimeFormatter( RscTop * pSuper, RscTop * pClassTime,
RscEnum * pTimeFieldFormat );
@@ -240,8 +239,8 @@ class RscTypCont
RscTop * InitClassMetricBox( RscTop * pSuper );
RscTop * InitClassCurrencyBox( const char * pClassName, sal_uInt32 nRT,
RscTop * pSuper );
- RscTop * InitClassDateBox( RscTop * pSuper, RscTop * pClassDate );
- RscTop * InitClassTimeBox( RscTop * pSuper, RscTop * pClassTime );
+ RscTop * InitClassDateBox( RscTop * pSuper );
+ RscTop * InitClassTimeBox( RscTop * pSuper );
RscTop * InitClassDockingWindow( RscTop * pSuper,
RscEnum * pMapUnit );
@@ -254,8 +253,7 @@ class RscTypCont
RscTop * InitClassMoreButton( RscTop * pSuper, RscEnum * pMapUnit );
RscTop * InitClassFloatingWindow( RscTop * pSuper,
RscEnum * pMapUnit );
- RscTop * InitClassTabControlItem( RscTop * pSuper,
- RscTop * pClassTabPage );
+ RscTop * InitClassTabControlItem( RscTop * pSuper );
RscTop * InitClassTabControl( RscTop * pSuper,
RscTop * pClassTabControlItem );
RscTop * InitClassSfxStyleFamilyItem( RscTop * pSuper,
@@ -343,7 +341,7 @@ public:
void ClearSysNames();
ERRTYPE WriteRc( WriteRcContext& rContext );
void WriteSrc( FILE * fOutput, sal_uLong nFileIndex,
- CharSet nCharSet, sal_Bool bName = sal_True );
+ sal_Bool bName = sal_True );
ERRTYPE WriteHxx( FILE * fOutput, sal_uLong nFileKey);
ERRTYPE WriteCxx( FILE * fOutput, sal_uLong nFileKey,
const rtl::OString& rHxxName );
diff --git a/rsc/source/parser/rscdb.cxx b/rsc/source/parser/rscdb.cxx
index 3c8d93d33ba5..ce35473b869a 100644
--- a/rsc/source/parser/rscdb.cxx
+++ b/rsc/source/parser/rscdb.cxx
@@ -715,7 +715,7 @@ ERRTYPE RscTypCont::WriteRc( WriteRcContext& rContext )
|*
*************************************************************************/
void RscTypCont :: WriteSrc( FILE * fOutput, sal_uLong nFileKey,
- CharSet /*nCharSet*/, sal_Bool bName )
+ sal_Bool bName )
{
RscFile * pFName;
RscEnumerateRef aEnumRef( this, pRoot, fOutput );
diff --git a/rsc/source/parser/rscicpx.cxx b/rsc/source/parser/rscicpx.cxx
index ad70349f17b0..ee50a73e44ce 100644
--- a/rsc/source/parser/rscicpx.cxx
+++ b/rsc/source/parser/rscicpx.cxx
@@ -192,7 +192,7 @@ RscTop * RscTypCont::InitClassImage( RscTop * pSuper, RscTop * pClassBitmap,
/*************************************************************************
|* RscTypCont::InitClassImageList()
*************************************************************************/
-RscTop * RscTypCont::InitClassImageList( RscTop * pSuper, RscTop * /*pClassBitmap*/,
+RscTop * RscTypCont::InitClassImageList( RscTop * pSuper,
RscTop * pClassColor, RscCont * pStrLst )
{
Atom nId;
@@ -1450,10 +1450,7 @@ RscTop * RscTypCont::InitClassMetricFormatter( RscTop * pSuper,
/*************************************************************************
|* RscTypCont::InitClassCurrencyFormatter()
*************************************************************************/
-RscTop * RscTypCont::InitClassCurrencyFormatter
-(
- RscTop * pSuper,
- RscEnum * /* pFieldUnits */)
+RscTop * RscTypCont::InitClassCurrencyFormatter(RscTop * pSuper)
{
Atom nId;
RscTop * pClassCurrency;
@@ -1802,8 +1799,7 @@ RscTop * RscTypCont::InitClassCurrencyBox
/*************************************************************************
|* RscTypCont::InitClassDateBox()
*************************************************************************/
-RscTop * RscTypCont::InitClassDateBox( RscTop * pSuper,
- RscTop * /*pClassDate*/ )
+RscTop * RscTypCont::InitClassDateBox( RscTop * pSuper )
{
Atom nId;
RscTop * pClassDateBox;
@@ -1823,8 +1819,7 @@ RscTop * RscTypCont::InitClassDateBox( RscTop * pSuper,
/*************************************************************************
|* RscTypCont::InitClassTimeBox()
*************************************************************************/
-RscTop * RscTypCont::InitClassTimeBox( RscTop * pSuper,
- RscTop * /*pClassTime*/ )
+RscTop * RscTypCont::InitClassTimeBox( RscTop * pSuper )
{
Atom nId;
RscTop * pClassTimeBox;
@@ -2187,8 +2182,7 @@ RscTop * RscTypCont::InitClassFloatingWindow( RscTop * pSuper,
/*************************************************************************
|* RscTypCont::InitClassTabControlItem()
*************************************************************************/
-RscTop * RscTypCont::InitClassTabControlItem( RscTop * pSuper,
- RscTop * /*pClassTabPage*/ )
+RscTop * RscTypCont::InitClassTabControlItem( RscTop * pSuper )
{
Atom nId;
RscTop * pClassTabControlItem;
diff --git a/rsc/source/parser/rscinit.cxx b/rsc/source/parser/rscinit.cxx
index 697ee6b7f05e..9034e2f7b89c 100644
--- a/rsc/source/parser/rscinit.cxx
+++ b/rsc/source/parser/rscinit.cxx
@@ -416,7 +416,7 @@ void RscTypCont::Init()
pRoot->Insert( pClassImage );
/********** I M A G E L I S T ****************************************/
- pClassImageList = InitClassImageList( pClassMgr, pClassBitmap,
+ pClassImageList = InitClassImageList( pClassMgr,
pClassColor, pStringLongTupelList );
pRoot->Insert( pClassImageList );
@@ -723,7 +723,7 @@ void RscTypCont::Init()
{ // Mehrfachvererbung von Hand
RscTop * pClassTmp = InitClassNumericFormatter( pClassSpinField );
aBaseLst.push_back( pClassTmp );
- pClassTmp = InitClassCurrencyFormatter( pClassTmp, pFieldUnits );
+ pClassTmp = InitClassCurrencyFormatter( pClassTmp );
aBaseLst.push_back( pClassTmp );
pClassCurrencyField = InitClassCurrencyField( "CurrencyField", RSC_CURRENCYFIELD, pClassTmp );
@@ -782,7 +782,7 @@ void RscTypCont::Init()
{ // Mehrfachvererbung von Hand
RscTop * pClassTmp = InitClassNumericFormatter( pClassComboBox );
aBaseLst.push_back( pClassTmp );
- pClassTmp = InitClassCurrencyFormatter( pClassTmp, pFieldUnits );
+ pClassTmp = InitClassCurrencyFormatter( pClassTmp );
aBaseLst.push_back( pClassTmp );
pClassCurrencyBox = InitClassCurrencyBox( "CurrencyBox", RSC_CURRENCYBOX, pClassTmp );
@@ -796,7 +796,7 @@ void RscTypCont::Init()
RscTop * pClassTmp = InitClassDateFormatter( pClassComboBox, pClassDate );
aBaseLst.push_back( pClassTmp );
- pClassDateBox = InitClassDateBox( pClassTmp, pClassDate );
+ pClassDateBox = InitClassDateBox( pClassTmp );
pRoot->Insert( pClassDateBox );
}
/********** T I M E B O X ********************************************/
@@ -805,7 +805,7 @@ void RscTypCont::Init()
pTimeFieldFormat );
aBaseLst.push_back( pClassTmp );
- pClassTimeBox = InitClassTimeBox( pClassTmp, pClassTime );
+ pClassTimeBox = InitClassTimeBox( pClassTmp );
pRoot->Insert( pClassTimeBox );
}
/********** D O C K I N G W I N D O W ********************************/
@@ -854,8 +854,7 @@ void RscTypCont::Init()
pRoot->Insert( pClassTabDialog );
/********** T A B C O N T R O L I T E M *******************************/
- pClassTabControlItem = InitClassTabControlItem( pClassMgr,
- pClassTabPage );
+ pClassTabControlItem = InitClassTabControlItem( pClassMgr );
pRoot->Insert( pClassTabControlItem );
/********** T A B C O N T R O L **************************************/
diff --git a/rsc/source/rsc/rsc.cxx b/rsc/source/rsc/rsc.cxx
index fc80beac2444..969af5852ea3 100644
--- a/rsc/source/rsc/rsc.cxx
+++ b/rsc/source/rsc/rsc.cxx
@@ -536,8 +536,7 @@ void RscCompiler::EndCompile()
{
if( !pFN->IsIncFile() )
{
- pTC->WriteSrc( foutput, NOFILE_INDEX,
- RTL_TEXTENCODING_UNICODE, sal_False );
+ pTC->WriteSrc( foutput, NOFILE_INDEX, sal_False );
break; // ?T 281091MM nur eine Src-Datei
}
};
@@ -1019,7 +1018,7 @@ ERRTYPE RscCompiler::Link()
pTC->pEH->FatalError( ERR_OPENFILE, RscId(), aTmpOutputSrc.getStr() );
// Schreibe Datei
- pTC->WriteSrc( foutput, NOFILE_INDEX, RTL_TEXTENCODING_UNICODE );
+ pTC->WriteSrc( foutput, NOFILE_INDEX );
fclose( foutput );
fExitFile = NULL;