Trying to keep up with the changes a little better by sending smaller
files. Hope I didn't mess up this diff as I'm new to git, and I had
to stash to pull in some upstream changes. Please review!
This is my first attempt at the sc/source/core/tool directory.
Hopefully the diff is attached below properly, but if not it should be
available at the following url for a few days:
http://dl.dropbox.com/u/18377756/topround_20110115_diff.txt
On another note, is there an automated test suite? If so, I'd love to
know how to kick it off after I make changes.
Regards,
PS: hopefully my name shows up in the email address now, but Topround is fine :)
diff --git a/sc/source/core/tool/addincol.cxx b/sc/source/core/tool/addincol.cxx
old mode 100644
new mode 100755
index 2bc3760..73959cd
--- a/sc/source/core/tool/addincol.cxx
+++ b/sc/source/core/tool/addincol.cxx
@@ -318,37 +318,33 @@ void ScUnoAddInCollection::Initialize()
while ( xEnum->hasMoreElements() )
{
uno::Any aAddInAny = xEnum->nextElement();
-//? if ( aAddInAny.getReflection()->getTypeClass() == uno::TypeClass_INTERFACE )
- {
- uno::Reference<uno::XInterface> xIntFac;
- aAddInAny >>= xIntFac;
- if ( xIntFac.is() )
- {
- // #i59984# try XSingleComponentFactory in addition to (old)
XSingleServiceFactory,
- // passing the context to the component
-
- uno::Reference<uno::XInterface> xInterface;
- uno::Reference<uno::XComponentContext> xCtx = getContext(xManager);
- uno::Reference<lang::XSingleComponentFactory> xCFac( xIntFac,
uno::UNO_QUERY );
- if (xCtx.is() && xCFac.is())
- {
- xInterface = xCFac->createInstanceWithContext(xCtx);
- if (xInterface.is())
- ReadFromAddIn( xInterface );
- }
-
- if (!xInterface.is())
- {
- uno::Reference<lang::XSingleServiceFactory> xFac( xIntFac,
uno::UNO_QUERY );
- if ( xFac.is() )
- {
- xInterface = xFac->createInstance();
- if (xInterface.is())
- ReadFromAddIn( xInterface );
- }
- }
- }
- }
+ uno::Reference<uno::XInterface> xIntFac;
+ aAddInAny >>= xIntFac;
+ if ( xIntFac.is() )
+ {
+ // #i59984# try XSingleComponentFactory in addition to
(old) XSingleServiceFactory,
+ // passing the context to the component
+ uno::Reference<uno::XInterface> xInterface;
+ uno::Reference<uno::XComponentContext> xCtx =
getContext(xManager);
+ uno::Reference<lang::XSingleComponentFactory> xCFac(
xIntFac, uno::UNO_QUERY );
+ if (xCtx.is() && xCFac.is())
+ {
+ xInterface = xCFac->createInstanceWithContext(xCtx);
+ if (xInterface.is())
+ ReadFromAddIn( xInterface );
+ }
+
+ if (!xInterface.is())
+ {
+ uno::Reference<lang::XSingleServiceFactory> xFac(
xIntFac, uno::UNO_QUERY );
+ if ( xFac.is() )
+ {
+ xInterface = xFac->createInstance();
+ if (xInterface.is())
+ ReadFromAddIn( xInterface );
+ }
+ }
+ }
}
}
}
@@ -715,9 +711,6 @@ BOOL lcl_ValidReturnType( const uno::Reference<reflection::XIdlClass>& xClass )
switch (xClass->getTypeClass())
{
- // case uno::TypeClass_VOID:
- // ???
-
case uno::TypeClass_ANY: // variable type
case uno::TypeClass_ENUM: //! ???
case uno::TypeClass_BOOLEAN:
diff --git a/sc/source/core/tool/addinlis.cxx b/sc/source/core/tool/addinlis.cxx
old mode 100644
new mode 100755
index 6f5cd1a..3832d50
--- a/sc/source/core/tool/addinlis.cxx
+++ b/sc/source/core/tool/addinlis.cxx
@@ -46,8 +46,6 @@ using namespace com::sun::star;
//------------------------------------------------------------------------
-//SMART_UNO_IMPLEMENTATION( ScAddInListener, UsrObject );
-
SC_SIMPLE_SERVICE_INFO( ScAddInListener, "ScAddInListener", "stardiv.one.sheet.AddInListener" )
//------------------------------------------------------------------------
diff --git a/sc/source/core/tool/address.cxx b/sc/source/core/tool/address.cxx
old mode 100644
new mode 100755
index 0d4a70c..5a650f9
--- a/sc/source/core/tool/address.cxx
+++ b/sc/source/core/tool/address.cxx
@@ -1639,7 +1639,6 @@ void ScAddress::Format( String& r, USHORT nFlags, ScDocument* pDoc,
r = ScGlobal::GetRscString( STR_NOREF_STR );
return;
}
-// if( nFlags & ( SCA_TAB_ABSOLUTE | SCA_TAB_3D ) )
if( nFlags & SCA_TAB_3D )
{
String aTabName, aDocName;
diff --git a/sc/source/core/tool/autoform.cxx b/sc/source/core/tool/autoform.cxx
old mode 100644
new mode 100755
index 2bb2a09..ed8ebc7
--- a/sc/source/core/tool/autoform.cxx
+++ b/sc/source/core/tool/autoform.cxx
@@ -1038,8 +1038,6 @@ BOOL ScAutoFormat::Load()
BYTE nChrSet, nCnt;
long nPos = rStream.Tell();
rStream >> nCnt >> nChrSet;
-// if( 4 <= nCnt )
-// rStream >> nFileVers;
if( rStream.Tell() != ULONG(nPos + nCnt) )
{
DBG_ERRORFILE( "Der Header enthaelt mehr/neuere Daten" );
@@ -1136,9 +1134,6 @@ BOOL ScAutoFormat::Save()
<< (BYTE)2 // Anzahl von Zeichen des Headers incl. diesem
<< (BYTE)::GetSOStoreTextEncoding(
gsl_getSystemTextEncoding(),
sal::static_int_cast<USHORT>(rStream.GetVersion()) );
-// << (BYTE)4 // Anzahl von Zeichen des Headers incl.
diesem
-// << (BYTE)::GetStoreCharSet(::GetSystemCharSet())
-// << (UNIT16)SOFFICE_FILEFORMAT_NOW;
ScAfVersions::Write(rStream); // Item-Versionen
bRet = (rStream.GetError() == 0);
diff --git a/sc/source/core/tool/callform.cxx b/sc/source/core/tool/callform.cxx
old mode 100644
new mode 100755
index 808776f..d555604
--- a/sc/source/core/tool/callform.cxx
+++ b/sc/source/core/tool/callform.cxx
@@ -106,7 +106,6 @@ typedef void (CALLTYPE* FARPROC) ( void );
FuncData::FuncData(const String& rIName) :
pModuleData (NULL),
aInternalName (rIName),
-// aFuncName (""),
nNumber (0),
nParamCount (0),
eAsyncType (NONE)
@@ -434,7 +433,6 @@ BOOL FuncData::Unadvice( double nHandle )
const String& FuncData::GetModuleName() const
{
- // DBG_ASSERT( pModuleData, "Keine Arme, keine Kekse" ):
return pModuleData->GetName();
}
diff --git a/sc/source/core/tool/chartarr.cxx b/sc/source/core/tool/chartarr.cxx
old mode 100644
new mode 100755
index 70ad606..78764f7
--- a/sc/source/core/tool/chartarr.cxx
+++ b/sc/source/core/tool/chartarr.cxx
@@ -248,8 +248,6 @@ ScMemChart* ScChartArray::CreateMemChartSingle()
static_cast<short>(nColCount), static_cast<short>(nRowCount) );
if (pMemChart)
{
-// SvNumberFormatter* pFormatter = pDocument->GetFormatTable();
-// pMemChart->SetNumberFormatter( pFormatter );
if ( bValidData )
{
BOOL bCalcAsShown = pDocument->GetDocOptions().IsCalcAsShown();
@@ -308,16 +306,11 @@ ScMemChart* ScChartArray::CreateMemChartSingle()
{
aString = ScGlobal::GetRscString(STR_COLUMN);
aString += ' ';
-// aString += String::CreateFromInt32( pCols[nCol]+1 );
ScAddress aPos( aCols[ nCol ], 0, 0 );
aPos.Format( aColStr, SCA_VALID_COL, NULL );
aString += aColStr;
}
pMemChart->SetColText( static_cast<short>(nCol), aString);
-
-// ULONG nNumberAttr = (nTotalRows ? pDocument->GetNumberFormat(
-// ScAddress( pCols[nCol], nRow1, nTab1)) : 0);
-// pMemChart->SetNumFormatIdCol( static_cast<long>(nCol), nNumberAttr );
}
//
@@ -339,37 +332,7 @@ ScMemChart* ScChartArray::CreateMemChartSingle()
aString += String::CreateFromInt32( aRows[nRow]+1 );
}
pMemChart->SetRowText( static_cast<short>(nRow), aString);
-
-// ULONG nNumberAttr = (nTotalCols ? pDocument->GetNumberFormat(
-// ScAddress( nCol1, pRows[nRow], nTab1)) : 0);
-// pMemChart->SetNumFormatIdRow( static_cast<long>(nRow), nNumberAttr );
}
-
- //
- // Titel
- //
-
-// pMemChart->SetMainTitle(ScGlobal::GetRscString(STR_CHART_MAINTITLE));
-// pMemChart->SetSubTitle(ScGlobal::GetRscString(STR_CHART_SUBTITLE));
-// pMemChart->SetXAxisTitle(ScGlobal::GetRscString(STR_CHART_XTITLE));
-// pMemChart->SetYAxisTitle(ScGlobal::GetRscString(STR_CHART_YTITLE));
-// pMemChart->SetZAxisTitle(ScGlobal::GetRscString(STR_CHART_ZTITLE));
-
- //
- // Zahlen-Typ
- //
-
-// ULONG nNumberAttr = (nTotalCols && nTotalRows ?
-// pDocument->GetNumberFormat( ScAddress( nCol1, nRow1, nTab1)) :
-// 0);
-// if (pFormatter)
-// pMemChart->SetDataType(pFormatter->GetType( nNumberAttr ));
-
- //
- // Parameter-Strings
- //
-
-// SetExtraStrings( *pMemChart );
}
return pMemChart;
@@ -409,7 +372,6 @@ ScMemChart* ScChartArray::CreateMemChartMulti()
{
SCSIZE nCol = 0;
SCSIZE nRow = 0;
-// pMemChart->SetNumberFormatter( pDocument->GetFormatTable() );
BOOL bCalcAsShown = pDocument->GetDocOptions().IsCalcAsShown();
ULONG nIndex = 0;
if (bValidData)
@@ -504,16 +466,9 @@ ScMemChart* ScChartArray::CreateMemChartMulti()
nPosCol++;
ScAddress aPos( nPosCol - 1, 0, 0 );
aPos.Format( aColStr, SCA_VALID_COL, NULL );
-// aString += String::CreateFromInt32( nPosCol );
aString += aColStr;
}
pMemChart->SetColText( static_cast<short>(nCol), aString);
-
-// ULONG nNumberAttr = 0;
-// pPos = GetPositionMap()->GetPosition( nCol, 0 );
-// if ( pPos )
-// nNumberAttr = pDocument->GetNumberFormat( *pPos );
-// pMemChart->SetNumFormatIdCol( static_cast<long>(nCol), nNumberAttr );
}
//
@@ -541,47 +496,7 @@ ScMemChart* ScChartArray::CreateMemChartMulti()
aString += String::CreateFromInt32( nPosRow );
}
pMemChart->SetRowText( static_cast<short>(nRow), aString);
-
-// ULONG nNumberAttr = 0;
-// pPos = GetPositionMap()->GetPosition( 0, nRow );
-// if ( pPos )
-// nNumberAttr = pDocument->GetNumberFormat( *pPos );
-// pMemChart->SetNumFormatIdRow( static_cast<long>(nRow), nNumberAttr );
}
-
- //
- // Titel
- //
-
-// pMemChart->SetMainTitle(ScGlobal::GetRscString(STR_CHART_MAINTITLE));
-// pMemChart->SetSubTitle(ScGlobal::GetRscString(STR_CHART_SUBTITLE));
-// pMemChart->SetXAxisTitle(ScGlobal::GetRscString(STR_CHART_XTITLE));
-// pMemChart->SetYAxisTitle(ScGlobal::GetRscString(STR_CHART_YTITLE));
-// pMemChart->SetZAxisTitle(ScGlobal::GetRscString(STR_CHART_ZTITLE));
-
- //
- // Zahlen-Typ
- //
-
-// SvNumberFormatter* pFormatter = pDocument->GetFormatTable();
-// if (pFormatter)
-// {
-// ULONG nIndex = 0;
-// ULONG nCount = GetPositionMap()->GetCount();
-// const ScAddress* pPos;
-// do
-// {
-// pPos = GetPositionMap()->GetPosition( nIndex );
-// } while ( !pPos && ++nIndex < nCount );
-// ULONG nFormat = ( pPos ? pDocument->GetNumberFormat( *pPos ) : 0 );
-// pMemChart->SetDataType( pFormatter->GetType( nFormat ) );
-// }
-
- //
- // Parameter-Strings
- //
-
-// SetExtraStrings( *pMemChart );
}
return pMemChart;
diff --git a/sc/source/core/tool/chartlis.cxx b/sc/source/core/tool/chartlis.cxx
old mode 100644
new mode 100755
index 45ca915..6fb34ff
--- a/sc/source/core/tool/chartlis.cxx
+++ b/sc/source/core/tool/chartlis.cxx
@@ -221,7 +221,6 @@ void ScChartListener::SetUno(
const uno::Reference< chart::XChartDataChangeEventListener >& rListener,
const uno::Reference< chart::XChartData >& rSource )
{
-// DBG_ASSERT( rListener.is() && rSource.is(), "Nullpointer bei SetUno" );
delete pUnoData;
pUnoData = new ScChartUnoData( rListener, rSource );
}
diff --git a/sc/source/core/tool/compiler.cxx b/sc/source/core/tool/compiler.cxx
old mode 100644
new mode 100755
index 844a901..0bcc4f4
--- a/sc/source/core/tool/compiler.cxx
+++ b/sc/source/core/tool/compiler.cxx
@@ -912,9 +912,6 @@ struct ConventionOOO_A1 : public Convention_A1
ScComplexRefData aRef( rRef );
// In case absolute/relative positions weren't separately available:
// transform relative to absolute!
- // AdjustReference( aRef.Ref1 );
- // if( !bSingleRef )
- // AdjustReference( aRef.Ref2 );
aRef.Ref1.CalcAbsIfRel( rComp.GetPos() );
if( !bSingleRef )
aRef.Ref2.CalcAbsIfRel( rComp.GetPos() );
diff --git a/sc/source/core/tool/consoli.cxx b/sc/source/core/tool/consoli.cxx
old mode 100644
new mode 100755
index 4260acb..2e4e739
--- a/sc/source/core/tool/consoli.cxx
+++ b/sc/source/core/tool/consoli.cxx
@@ -50,22 +50,6 @@
// STATIC DATA -----------------------------------------------------------
-/* Strings bei Gelegenheit ganz raus...
-static USHORT nFuncRes[] = { // Reihenfolge wie bei enum
ScSubTotalFunc
- 0, // none
- STR_PIVOTFUNC_AVG,
- STR_PIVOTFUNC_COUNT,
- STR_PIVOTFUNC_COUNT2,
- STR_PIVOTFUNC_MAX,
- STR_PIVOTFUNC_MIN,
- STR_PIVOTFUNC_PROD,
- STR_PIVOTFUNC_STDDEV,
- STR_PIVOTFUNC_STDDEV2,
- STR_PIVOTFUNC_SUM,
- STR_PIVOTFUNC_VAR,
- STR_PIVOTFUNC_VAR2 };
-*/
-
static OpCode eOpCodeTable[] = { // Reihenfolge wie bei enum
ScSubTotalFunc
ocBad, // none
ocAverage,
@@ -185,8 +169,6 @@ void ScConsData::DeleteData()
ppRefs = NULL;
}
-// DELETEARR( ppData1, nColCount );
-// DELETEARR( ppData2, nColCount );
DELETEARR( ppCount, nColCount );
DELETEARR( ppSum, nColCount );
DELETEARR( ppSumSqr,nColCount );
diff --git a/sc/source/core/tool/ddelink.cxx b/sc/source/core/tool/ddelink.cxx
old mode 100644
new mode 100755
index ad72372..46c2555
--- a/sc/source/core/tool/ddelink.cxx
+++ b/sc/source/core/tool/ddelink.cxx
@@ -269,7 +269,6 @@ void ScDdeLink::TryUpdate()
else
{
bIsInUpdate = TRUE;
- //Application::Reschedule(); //! OS/2-Simulation
pDoc->IncInDdeLinkUpdate();
Update();
pDoc->DecInDdeLinkUpdate();
diff --git a/sc/source/core/tool/detfunc.cxx b/sc/source/core/tool/detfunc.cxx
old mode 100644
new mode 100755
index 4138e87..51e400a
--- a/sc/source/core/tool/detfunc.cxx
+++ b/sc/source/core/tool/detfunc.cxx
@@ -755,17 +755,6 @@ inline BOOL RectIsPoints( const Rectangle& rRect, const Point& rStart, const
Poi
void ScDetectiveFunc::DeleteBox( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2 )
{
-/* String aStr;
- aStr += nCol1;
- aStr += '/';
- aStr += nRow1;
- aStr += '/';
- aStr += nCol2;
- aStr += '/';
- aStr += nRow2;
- InfoBox(0,aStr).Execute();
-*/
-
Rectangle aCornerRect = GetDrawRect( nCol1, nRow1, nCol2, nRow2 );
Point aStartCorner = aCornerRect.TopLeft();
Point aEndCorner = aCornerRect.BottomRight();
@@ -1061,7 +1050,6 @@ USHORT ScDetectiveFunc::InsertSuccLevel( SCCOL nCol1, SCROW nRow1, SCCOL
nCol2,
// ueber ganzes Dokument
USHORT nResult = DET_INS_EMPTY;
-// ScCellIterator aCellIter( pDoc, 0,0, nTab, MAXCOL,MAXROW, nTab );
ScCellIterator aCellIter( pDoc, 0,0,0, MAXCOL,MAXROW,MAXTAB ); // alle
Tabellen
ScBaseCell* pCell = aCellIter.GetFirst();
while (pCell)
@@ -1585,12 +1573,10 @@ void ScDetectiveFunc::UpdateAllArrowColors()
if ( bArrow || bError )
{
ColorData nColorData = ( bError ? GetErrorColor() : GetArrowColor() );
- //pObject->SendRepaintBroadcast(pObject->GetBoundRect());
pObject->SetMergedItem( XLineColorItem( String(), Color( nColorData ) ) );
// repaint only
pObject->ActionChanged();
- // pObject->SendRepaintBroadcast(pObject->GetBoundRect());
}
}
}
diff --git a/sc/source/core/tool/doubleref.cxx b/sc/source/core/tool/doubleref.cxx
old mode 100644
new mode 100755
index e83ee37..34862ae
--- a/sc/source/core/tool/doubleref.cxx
+++ b/sc/source/core/tool/doubleref.cxx
@@ -178,10 +178,6 @@ bool lcl_createExcelQuery(
if (bValid)
{
-// ULONG nVisible = 0;
-// for ( nCol=nCol1; nCol<=nCol2; nCol++ )
-// nVisible += aCol[nCol].VisibleCount( nRow1+1, nRow2 );
-
// Count the number of visible cells (excluding the header row). Each
// visible cell corresponds with a single query.
SCSIZE nVisible = pQueryRef->getVisibleDataCellCount();
diff --git a/sc/source/core/tool/editutil.cxx b/sc/source/core/tool/editutil.cxx
old mode 100644
new mode 100755
index bea5887..a245e54
--- a/sc/source/core/tool/editutil.cxx
+++ b/sc/source/core/tool/editutil.cxx
@@ -681,7 +681,6 @@ String ScHeaderEditEngine::CalcFieldValue( const SvxFieldItem& rField,
aRet = ScGlobal::pLocaleData->getDate(aData.aDate);
else
{
- //DBG_ERROR("unbekannter Feldbefehl");
aRet = '?';
}
}
@@ -746,7 +745,6 @@ String ScFieldEditEngine::CalcFieldValue( const SvxFieldItem& rField,
}
else
{
- //DBG_ERROR("unbekannter Feldbefehl");
aRet = '?';
}
}
diff --git a/sc/source/core/tool/filtopt.cxx b/sc/source/core/tool/filtopt.cxx
old mode 100644
new mode 100755
index d62a905..3e92221
--- a/sc/source/core/tool/filtopt.cxx
+++ b/sc/source/core/tool/filtopt.cxx
@@ -78,7 +78,6 @@ ScFilterOptions::ScFilterOptions() :
{
Sequence<OUString> aNames = GetPropertyNames();
Sequence<Any> aValues = GetProperties(aNames);
-// EnableNotification(aNames);
const Any* pValues = aValues.getConstArray();
DBG_ASSERT(aValues.getLength() == aNames.getLength(), "GetProperties failed");
if(aValues.getLength() == aNames.getLength())
diff --git a/sc/source/core/tool/interpr2.cxx b/sc/source/core/tool/interpr2.cxx
old mode 100644
new mode 100755
index d548844..1979997
--- a/sc/source/core/tool/interpr2.cxx
+++ b/sc/source/core/tool/interpr2.cxx
@@ -1762,7 +1762,6 @@ void ScInterpreter::ScBackSolver()
// Try a nice rounded input value if possible.
const double fNiceDelta = (bDoneIteration && fabs(fBestX) >= 1e-3 ? 1e-3 : fDelta);
double nX = ::rtl::math::approxFloor((fBestX / fNiceDelta) + 0.5) * fNiceDelta;
-// double nX = ::rtl::math::approxFloor((fBestX / fDelta) + 0.5) * fDelta;
if ( bDoneIteration )
{
diff --git a/sc/source/core/tool/interpr3.cxx b/sc/source/core/tool/interpr3.cxx
old mode 100644
new mode 100755
index 0bbc1f1..395562d
--- a/sc/source/core/tool/interpr3.cxx
+++ b/sc/source/core/tool/interpr3.cxx
@@ -460,10 +460,6 @@ double ScInterpreter::Fakultaet(double x)
}
else
SetError(errNoValue);
-/* // Stirlingsche Naeherung zu ungenau
- else
- x = pow(x/exp(1), x) * sqrt(x) * SQRT_2_PI * (1.0 + 1.0 / (12.0 * x));
-*/
return x;
}
@@ -2399,9 +2395,6 @@ bool ScInterpreter::CalculateTest(BOOL _bTemplin
}
fT = fabs(fSum1/fCount1 - fSum2/fCount2)/sqrt(fS1+fS2);
double c = fS1/(fS1+fS2);
-// s.u. fF = ::rtl::math::approxFloor(1.0/(c*c/(fCount1-1.0)+(1.0-c)*(1.0-c)/(fCount2-1.0)));
-// fF = ::rtl::math::approxFloor((fS1+fS2)*(fS1+fS2)/(fS1*fS1/(fCount1-1.0) +
fS2*fS2/(fCount2-1.0)));
-
// GetTDist wird mit GetBetaDist berechnet und kommt auch mit nicht ganzzahligen
// Freiheitsgraden klar. Dann stimmt das Ergebnis auch mit Excel ueberein (#52406#):
fF = 1.0/(c*c/(fCount1-1.0)+(1.0-c)*(1.0-c)/(fCount2-1.0));
@@ -3224,7 +3217,6 @@ void ScInterpreter::CalculateSmallLarge(BOOL bSmall)
* actually are defined to return an array of values if an array of
* positions was passed, in which case, depending on the number of values,
* we may or will need a real sorted array again, see #i32345. */
- //GetSortArray(1, aSortArray);
GetNumberSequenceArray(1, aSortArray);
SCSIZE nSize = aSortArray.size();
if (aSortArray.empty() || nSize == 0 || nGlobalError || nSize < k)
diff --git a/sc/source/core/tool/interpr4.cxx b/sc/source/core/tool/interpr4.cxx
old mode 100644
new mode 100755
index 27164e6..c97e11e
--- a/sc/source/core/tool/interpr4.cxx
+++ b/sc/source/core/tool/interpr4.cxx
@@ -3706,7 +3706,6 @@ StackVar ScInterpreter::Interpret()
case ocMacro : ScMacro(); break;
case ocDBArea : ScDBArea(); break;
case ocColRowNameAuto : ScColRowNameAuto(); break;
-// separated case ocPush : Push( (ScToken&) *pCur ); break;
case ocIf : ScIfJump(); break;
case ocChose : ScChoseJump(); break;
case ocAdd : ScAdd(); break;
diff --git a/sc/source/core/tool/optutil.cxx b/sc/source/core/tool/optutil.cxx
old mode 100644
new mode 100755
index 5c461e3..0245541
--- a/sc/source/core/tool/optutil.cxx
+++ b/sc/source/core/tool/optutil.cxx
@@ -44,7 +44,6 @@ BOOL ScOptionsUtil::IsMetricSystem()
{
//! which language should be used here - system language or installed office language?
-// MeasurementSystem eSys = Application::GetAppInternational().GetMeasurementSystem();
MeasurementSystem eSys = ScGlobal::pLocaleData->getMeasurementSystemEnum();
return ( eSys == MEASURE_METRIC );
diff --git a/sc/source/core/tool/printopt.cxx b/sc/source/core/tool/printopt.cxx
old mode 100644
new mode 100755
index 7af77de..4f7ef93
--- a/sc/source/core/tool/printopt.cxx
+++ b/sc/source/core/tool/printopt.cxx
@@ -151,7 +151,6 @@ ScPrintCfg::ScPrintCfg() :
{
Sequence<OUString> aNames = GetPropertyNames();
Sequence<Any> aValues = GetProperties(aNames);
-// EnableNotification(aNames);
const Any* pValues = aValues.getConstArray();
DBG_ASSERT(aValues.getLength() == aNames.getLength(), "GetProperties failed");
if(aValues.getLength() == aNames.getLength())
diff --git a/sc/source/core/tool/progress.cxx b/sc/source/core/tool/progress.cxx
old mode 100644
new mode 100755
index 58b8fd3..9cb9572
--- a/sc/source/core/tool/progress.cxx
+++ b/sc/source/core/tool/progress.cxx
@@ -178,7 +178,6 @@ void ScProgress::DeleteInterpretProgress()
a refresh of the sheet window which may call CreateInterpretProgress
and DeleteInterpretProgress again (from Output::DrawStrings),
resulting in double deletion of 'pInterpretProgress'. */
-// if ( --nInterpretProgress == 0 )
if ( nInterpretProgress == 1 )
{
if ( pInterpretProgress != &theDummyInterpretProgress )
diff --git a/sc/source/core/tool/rangenam.cxx b/sc/source/core/tool/rangenam.cxx
old mode 100644
new mode 100755
index 008d5f4..9fa4837
--- a/sc/source/core/tool/rangenam.cxx
+++ b/sc/source/core/tool/rangenam.cxx
@@ -136,15 +136,6 @@ ScRangeData::ScRangeData( ScDocument* pDok,
else
eType = eType | RT_ABSAREA;
}
- // Die Importfilter haben diesen Test nicht,
- // da die benannten Bereiche z.T. noch unvollstaendig sind.
-// if( !pCode->GetCodeLen() )
-// {
-// // ggf. den Fehlercode wg. unvollstaendiger Formel setzen!
-// ScCompiler aComp( pDok, aPos, *pCode );
-// aComp.CompileTokenArray();
-// pCode->DelRPN();
-// }
}
}
@@ -233,10 +224,6 @@ void ScRangeData::GuessPosition()
}
aPos = ScAddress( (SCCOL)(-nMinCol), (SCROW)(-nMinRow), (SCTAB)(-nMinTab) );
-
- //! Test
-// DBG_ERROR(String("Pos ")+String((SCCOL)(-nMinCol))+String("/")+
-// String((SCROW)(-nMinRow))+String("/")+String((SCTAB)(-nMinTab)));
}
void ScRangeData::GetSymbol( String& rSymbol, const FormulaGrammar::Grammar eGrammar ) const
@@ -441,7 +428,6 @@ void ScRangeData::UpdateTabRef(SCTAB nOldTable, USHORT nFlag, SCTAB nNewTable)
void ScRangeData::MakeValidName( String& rName ) // static
{
- //ScCompiler::InitSymbolsNative();
// strip leading invalid characters
xub_StrLen nPos = 0;
diff --git a/sc/source/core/tool/rangeseq.cxx b/sc/source/core/tool/rangeseq.cxx
old mode 100644
new mode 100755
index 8548ee8..0fc3815
--- a/sc/source/core/tool/rangeseq.cxx
+++ b/sc/source/core/tool/rangeseq.cxx
@@ -431,8 +431,6 @@ ScMatrixRef ScSequenceToMatrix::CreateMixedMatrix( const com::sun::star::uno::An
{
// Try string, else use empty as last resort.
- //Reflection* pRefl = pColArr[nCol].getReflection();
- //if ( pRefl->equals( *OUString_getReflection() ) )
if ( pColArr[nCol] >>= aUStr )
xMatrix->PutString( String( aUStr ),
static_cast<SCSIZE>(nCol),
diff --git a/sc/source/core/tool/token.cxx b/sc/source/core/tool/token.cxx
old mode 100644
new mode 100755
index 9dc0efc..7ae079c
--- a/sc/source/core/tool/token.cxx
+++ b/sc/source/core/tool/token.cxx
@@ -1474,8 +1474,6 @@ FormulaToken* ScTokenArray::MergeArray( )
if( nCol <= 0 || nRow <= 0 )
return NULL;
- // fprintf (stderr, "Array (cols = %d, rows = %d)\n", nCol, nRow );
-
int nSign = 1;
ScMatrix* pArray = new ScMatrix( nCol, nRow );
for ( i = nStart, nCol = 0, nRow = 0 ; i < nLen ; i++ )
Context
- [Libreoffice] [PATCH] partial easy hack - removal of non-compiled / dead code in sc · Ed Dean
Privacy Policy |
Impressum (Legal Info) |
Copyright information: Unless otherwise specified, all text and images
on this website are licensed under the
Creative Commons Attribution-Share Alike 3.0 License.
This does not include the source code of LibreOffice, which is
licensed under the Mozilla Public License (
MPLv2).
"LibreOffice" and "The Document Foundation" are
registered trademarks of their corresponding registered owners or are
in actual use as trademarks in one or more countries. Their respective
logos and icons are also subject to international copyright laws. Use
thereof is explained in our
trademark policy.