diff options
Diffstat (limited to 'sc/source')
56 files changed, 104 insertions, 109 deletions
diff --git a/sc/source/core/data/column.cxx b/sc/source/core/data/column.cxx index fbbaf70dcc69..33e0a3bfbfb4 100644 --- a/sc/source/core/data/column.cxx +++ b/sc/source/core/data/column.cxx @@ -1749,7 +1749,7 @@ void ScColumn::CopyScenarioFrom( const ScColumn& rSrcCol ) aRefCxt.meMode = URM_COPY; aRefCxt.maRange = ScRange(nCol, nStart, nTab, nCol, nEnd, nTab); aRefCxt.mnTabDelta = nTab - rSrcCol.nTab; - UpdateReferenceOnCopy(aRefCxt, NULL); + UpdateReferenceOnCopy(aRefCxt); UpdateCompile(); } @@ -1779,7 +1779,7 @@ void ScColumn::CopyScenarioTo( ScColumn& rDestCol ) const aRefCxt.meMode = URM_COPY; aRefCxt.maRange = ScRange(rDestCol.nCol, nStart, rDestCol.nTab, rDestCol.nCol, nEnd, rDestCol.nTab); aRefCxt.mnTabDelta = rDestCol.nTab - nTab; - rDestCol.UpdateReferenceOnCopy(aRefCxt, NULL); + rDestCol.UpdateReferenceOnCopy(aRefCxt); rDestCol.UpdateCompile(); } @@ -3419,7 +3419,7 @@ SCsROW ScColumn::SearchStyle( return -1; } else - return pAttrArray->SearchStyle( nRow, pSearchStyle, bUp, NULL ); + return pAttrArray->SearchStyle( nRow, pSearchStyle, bUp ); } bool ScColumn::SearchStyleRange( @@ -3435,7 +3435,7 @@ bool ScColumn::SearchStyleRange( return false; } else - return pAttrArray->SearchStyleRange( rRow, rEndRow, pSearchStyle, bUp, NULL ); + return pAttrArray->SearchStyleRange( rRow, rEndRow, pSearchStyle, bUp ); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sc/source/core/data/column2.cxx b/sc/source/core/data/column2.cxx index 5118e568c712..06e3c1695371 100644 --- a/sc/source/core/data/column2.cxx +++ b/sc/source/core/data/column2.cxx @@ -644,7 +644,7 @@ sal_uInt16 ScColumn::GetOptimalColWidth( const ScPatternAttr* pPattern = GetPattern( 0 ); vcl::Font aFont; // font color doesn't matter here - pPattern->GetFont( aFont, SC_AUTOCOL_BLACK, pDev, &rZoomX, NULL ); + pPattern->GetFont( aFont, SC_AUTOCOL_BLACK, pDev, &rZoomX ); pDev->SetFont( aFont ); const SvxMarginItem* pMargin = static_cast<const SvxMarginItem*>(&pPattern->GetItem(ATTR_MARGIN)); long nMargin = (long) ( pMargin->GetLeftMargin() * nPPTX ) + @@ -1424,7 +1424,7 @@ SCROW ScColumn::FindNextVisibleRow(SCROW nRow, bool bForward) const { nRow--; SCROW nStartRow = MAXROW; - bool bHidden = pDocument->RowHidden(nRow, nTab, &nStartRow, NULL); + bool bHidden = pDocument->RowHidden(nRow, nTab, &nStartRow); if(bHidden) return std::max<SCROW>(0, nStartRow - 1); else @@ -1470,7 +1470,7 @@ SCROW ScColumn::FindNextVisibleRowWithContent( { nRow--; SCROW nStartRow = MAXROW; - bool bHidden = pDocument->RowHidden(nRow, nTab, &nStartRow, NULL); + bool bHidden = pDocument->RowHidden(nRow, nTab, &nStartRow); if (bHidden) { nRow = nStartRow - 1; diff --git a/sc/source/core/data/documen2.cxx b/sc/source/core/data/documen2.cxx index 3b96fb4e6b9f..dbf968631193 100644 --- a/sc/source/core/data/documen2.cxx +++ b/sc/source/core/data/documen2.cxx @@ -895,7 +895,7 @@ bool ScDocument::CopyTab( SCTAB nOldPos, SCTAB nNewPos, const ScMarkData* pOnlyM aRefCxt.meMode = URM_COPY; aRefCxt.maRange = ScRange(0, 0, nNewPos, MAXCOL, MAXROW, nNewPos); aRefCxt.mnTabDelta = nDz; - maTabs[nNewPos]->UpdateReference(aRefCxt, NULL); + maTabs[nNewPos]->UpdateReference(aRefCxt); maTabs[nNewPos]->UpdateInsertTabAbs(nNewPos); // move all paragraphs up by one!! maTabs[nOldPos]->UpdateInsertTab(aCxt); @@ -1004,7 +1004,7 @@ sal_uLong ScDocument::TransferTab( ScDocument* pSrcDoc, SCTAB nSrcPos, aRefCxt.meMode = URM_COPY; aRefCxt.maRange = ScRange(0, 0, nDestPos, MAXCOL, MAXROW, nDestPos); aRefCxt.mnTabDelta = nDestPos - nSrcPos; - maTabs[nDestPos]->UpdateReference(aRefCxt, NULL); + maTabs[nDestPos]->UpdateReference(aRefCxt); // Readjust self-contained absolute references to this sheet maTabs[nDestPos]->TestTabRefAbs(nSrcPos); diff --git a/sc/source/core/data/documen8.cxx b/sc/source/core/data/documen8.cxx index fdd9049453ac..81b8cda4aae8 100644 --- a/sc/source/core/data/documen8.cxx +++ b/sc/source/core/data/documen8.cxx @@ -833,7 +833,7 @@ void ScDocument::UpdateExternalRefLinks(vcl::Window* pWin) // Update failed. Notify the user. OUString aFile; - sfx2::LinkManager::GetDisplayNames(pRefLink, NULL, &aFile, NULL, NULL); + sfx2::LinkManager::GetDisplayNames(pRefLink, NULL, &aFile); // Decode encoded URL for display friendliness. INetURLObject aUrl(aFile,INetURLObject::WAS_ENCODED); aFile = aUrl.GetMainURL(INetURLObject::DECODE_UNAMBIGUOUS); diff --git a/sc/source/core/data/dpcache.cxx b/sc/source/core/data/dpcache.cxx index 56d9c07f732c..169d32ec1b5e 100644 --- a/sc/source/core/data/dpcache.cxx +++ b/sc/source/core/data/dpcache.cxx @@ -116,7 +116,7 @@ OUString createLabelString(ScDocument* pDoc, SCCOL nCol, SCROW nRow, SCTAB nTab) aBuf.append(' '); ScAddress aColAddr(nCol, 0, 0); - aBuf.append(aColAddr.Format(SCA_VALID_COL, NULL)); + aBuf.append(aColAddr.Format(SCA_VALID_COL)); aDocStr = aBuf.makeStringAndClear(); } return aDocStr; diff --git a/sc/source/core/data/table1.cxx b/sc/source/core/data/table1.cxx index 159f945b1ebe..f7097f14f2f7 100644 --- a/sc/source/core/data/table1.cxx +++ b/sc/source/core/data/table1.cxx @@ -1081,7 +1081,7 @@ SCCOL ScTable::FindNextVisibleCol( SCCOL nCol, bool bRight ) const { nCol--; SCCOL nStart = MAXCOL; - bool bHidden = pDocument->ColHidden(nCol, nTab, &nStart, nullptr); + bool bHidden = pDocument->ColHidden(nCol, nTab, &nStart); if(bHidden) nCol = nStart - 1; @@ -1124,7 +1124,7 @@ SCCOL ScTable::FindNextVisibleColWithContent( SCCOL nCol, bool bRight, SCROW nRo { nCol--; SCCOL nStartCol = MAXCOL; - bool bHidden = pDocument->ColHidden( nCol, nTab, &nStartCol, nullptr ); + bool bHidden = pDocument->ColHidden( nCol, nTab, &nStartCol ); if(bHidden) { nCol = nStartCol -1; diff --git a/sc/source/core/data/table6.cxx b/sc/source/core/data/table6.cxx index 3c24c8fd7c20..386843749c2a 100644 --- a/sc/source/core/data/table6.cxx +++ b/sc/source/core/data/table6.cxx @@ -45,7 +45,7 @@ bool lcl_GetTextWithBreaks( const EditTextObject& rData, ScDocument* pDoc, OUStr EditEngine& rEngine = pDoc->GetEditEngine(); rEngine.SetText(rData); - rVal = rEngine.GetText( LINEEND_LF ); + rVal = rEngine.GetText(); return ( rEngine.GetParagraphCount() > 1 ); } @@ -265,7 +265,7 @@ void ScTable::SkipFilteredRows(SCROW& rRow, SCROW& rLastNonFilteredRow, bool bFo return; SCROW nFirstRow = rRow; - if (RowFiltered(rRow, &nFirstRow, NULL)) + if (RowFiltered(rRow, &nFirstRow)) // move to the first non-filtered row. rRow = nFirstRow - 1; else diff --git a/sc/source/core/tool/address.cxx b/sc/source/core/tool/address.cxx index 2c39f1bcfcfb..d2ef8d984261 100644 --- a/sc/source/core/tool/address.cxx +++ b/sc/source/core/tool/address.cxx @@ -713,7 +713,7 @@ static sal_uInt16 lcl_ScRange_Parse_XL_R1C1( ScRange& r, sal_uInt16 nFlags2 = SCA_VALID_TAB; p = r.Parse_XL_Header( p, pDoc, aExternDocName, aStartTabName, - aEndTabName, nFlags, bOnlyAcceptSingle, NULL ); + aEndTabName, nFlags, bOnlyAcceptSingle ); if (!aExternDocName.isEmpty()) lcl_ScRange_External_TabSpan( r, nFlags, pExtInfo, aExternDocName, @@ -1325,7 +1325,7 @@ static sal_uInt16 lcl_ScAddress_Parse ( const sal_Unicode* p, ScDocument* pDoc, case formula::FormulaGrammar::CONV_OOO: { sal_uInt16 nRawRes = 0; - return lcl_ScAddress_Parse_OOo( p, pDoc, rAddr, nRawRes, pExtInfo, NULL ); + return lcl_ScAddress_Parse_OOo( p, pDoc, rAddr, nRawRes, pExtInfo ); } } } @@ -1461,7 +1461,7 @@ static sal_uInt16 lcl_ScRange_Parse_OOo( ScRange& rRange, aTmp[nPos] = 0; const sal_Unicode* p = aTmp.getStr(); sal_uInt16 nRawRes1 = 0; - if (((nRes1 = lcl_ScAddress_Parse_OOo( p, pDoc, rRange.aStart, nRawRes1, pExtInfo, NULL)) != 0) || + if (((nRes1 = lcl_ScAddress_Parse_OOo( p, pDoc, rRange.aStart, nRawRes1, pExtInfo)) != 0) || ((nRawRes1 & (SCA_VALID_COL | SCA_VALID_ROW)) && (nRawRes1 & SCA_VALID_TAB))) { rRange.aEnd = rRange.aStart; // sheet must be initialized identical to first sheet diff --git a/sc/source/core/tool/cellform.cxx b/sc/source/core/tool/cellform.cxx index 36529c6c9d91..3321686b51f6 100644 --- a/sc/source/core/tool/cellform.cxx +++ b/sc/source/core/tool/cellform.cxx @@ -274,7 +274,7 @@ OUString ScCellFormat::GetOutputString( ScDocument& rDoc, const ScAddress& rPos, { ScFieldEditEngine& rEngine = rDoc.GetEditEngine(); rEngine.SetText(*pData); - aVal = rEngine.GetText(LINEEND_LF); + aVal = rEngine.GetText(); } // also do not format EditCells as numbers // (fitting to output) diff --git a/sc/source/core/tool/chartarr.cxx b/sc/source/core/tool/chartarr.cxx index 33cbddbde7ad..0a9076cc5c62 100644 --- a/sc/source/core/tool/chartarr.cxx +++ b/sc/source/core/tool/chartarr.cxx @@ -272,7 +272,7 @@ ScMemChart* ScChartArray::CreateMemChartSingle() aBuf.append(' '); ScAddress aPos( aCols[ nCol ], 0, 0 ); - aBuf.append(aPos.Format(SCA_VALID_COL, NULL)); + aBuf.append(aPos.Format(SCA_VALID_COL)); aString = aBuf.makeStringAndClear(); } @@ -385,7 +385,7 @@ ScMemChart* ScChartArray::CreateMemChartMulti() else nPosCol++; ScAddress aPos( nPosCol - 1, 0, 0 ); - aBuf.append(aPos.Format(SCA_VALID_COL, NULL)); + aBuf.append(aPos.Format(SCA_VALID_COL)); aString = aBuf.makeStringAndClear(); } pMemChart->SetColText( nCol, aString); diff --git a/sc/source/core/tool/chgtrack.cxx b/sc/source/core/tool/chgtrack.cxx index 5a705ccff7a2..381e0ab5a70d 100644 --- a/sc/source/core/tool/chgtrack.cxx +++ b/sc/source/core/tool/chgtrack.cxx @@ -1256,7 +1256,7 @@ bool ScChangeActionMove::Reject( ScDocument* pDoc ) aCxt.mnColDelta = aFrmRange.aStart.Col() - aToRange.aStart.Col(); aCxt.mnRowDelta = aFrmRange.aStart.Row() - aToRange.aStart.Row(); aCxt.mnTabDelta = aFrmRange.aStart.Tab() - aToRange.aStart.Tab(); - pDoc->UpdateReference(aCxt, NULL); + pDoc->UpdateReference(aCxt); // Free LinkDependent, set succeeding UpdateReference Undo // ToRange->FromRange Dependents @@ -1999,9 +1999,9 @@ void ScChangeActionContent::UpdateReference( const ScChangeTrack* pTrack, aRefCxt.mnTabDelta = nDz; if ( bOldFormula ) - maOldCell.mpFormula->UpdateReference(aRefCxt, NULL); + maOldCell.mpFormula->UpdateReference(aRefCxt); if ( bNewFormula ) - maNewCell.mpFormula->UpdateReference(aRefCxt, NULL); + maNewCell.mpFormula->UpdateReference(aRefCxt); if ( !aBigRange.aStart.IsValid( pTrack->GetDocument() ) ) { //FIXME: diff --git a/sc/source/core/tool/interpr1.cxx b/sc/source/core/tool/interpr1.cxx index e4838e4251c1..4e8fce082bb6 100644 --- a/sc/source/core/tool/interpr1.cxx +++ b/sc/source/core/tool/interpr1.cxx @@ -2334,7 +2334,7 @@ void ScInterpreter::ScCellExternal() // For SHEET, No idea what number we should set, but let's always set // 1 if the external sheet exists, no matter what sheet. Excel does // the same. - if (pRefMgr->getCacheTable(nFileId, aTabName, false, NULL).get()) + if (pRefMgr->getCacheTable(nFileId, aTabName, false).get()) PushInt(1); else SetError(errNoName); diff --git a/sc/source/core/tool/interpr2.cxx b/sc/source/core/tool/interpr2.cxx index 5a59e5c33285..e702fc1cd4a3 100644 --- a/sc/source/core/tool/interpr2.cxx +++ b/sc/source/core/tool/interpr2.cxx @@ -1739,7 +1739,7 @@ bool ScInterpreter::RateIteration( double fNper, double fPayment, double fPv, // convert any fPayType situation to fPayType == zero situation fFv = fFv - fPayment * fPayType; fPv = fPv + fPayment * fPayType; - if (fNper == ::rtl::math::round( fNper, 0, rtl_math_RoundingMode_Corrected )) + if (fNper == ::rtl::math::round( fNper )) { // Nper is an integer value fX = fGuess; while (!bFound && nCount < nIterationsMax) diff --git a/sc/source/core/tool/progress.cxx b/sc/source/core/tool/progress.cxx index e533986480b9..72c2fbae7d81 100644 --- a/sc/source/core/tool/progress.cxx +++ b/sc/source/core/tool/progress.cxx @@ -75,7 +75,7 @@ ScProgress::ScProgress(SfxObjectShell* pObjSh, const OUString& rText, : bEnabled(true) { - if ( pGlobalProgress || SfxProgress::GetActiveProgress( NULL ) ) + if ( pGlobalProgress || SfxProgress::GetActiveProgress() ) { if ( lcl_IsHiddenDocument(pObjSh) ) { diff --git a/sc/source/core/tool/rangeutl.cxx b/sc/source/core/tool/rangeutl.cxx index 65a64d679cbe..c7e9d0c464e4 100644 --- a/sc/source/core/tool/rangeutl.cxx +++ b/sc/source/core/tool/rangeutl.cxx @@ -417,7 +417,7 @@ void ScRangeStringConverter::AppendTableName(OUStringBuffer& rBuf, const OUStrin { // quote character is always "'" OUString aQuotedTab(rTabName); - ScCompiler::CheckTabQuotes(aQuotedTab, ::formula::FormulaGrammar::CONV_OOO); + ScCompiler::CheckTabQuotes(aQuotedTab); rBuf.append(aQuotedTab); } diff --git a/sc/source/filter/excel/excform.cxx b/sc/source/filter/excel/excform.cxx index c5b52d3ff070..268dcfcacee2 100644 --- a/sc/source/filter/excel/excform.cxx +++ b/sc/source/filter/excel/excform.cxx @@ -149,7 +149,7 @@ void ImportExcel::Formula( } } - ConvErr eErr = pFormConv->Convert( pResult, maStrm, nFormLen, true, FT_CellFormula); + ConvErr eErr = pFormConv->Convert( pResult, maStrm, nFormLen, true ); ScFormulaCell* pCell = NULL; diff --git a/sc/source/filter/excel/impop.cxx b/sc/source/filter/excel/impop.cxx index 904209d2bb1b..17bf74111ae7 100644 --- a/sc/source/filter/excel/impop.cxx +++ b/sc/source/filter/excel/impop.cxx @@ -545,7 +545,7 @@ void ImportExcel::Array25() pFormConv->Reset( ScAddress( static_cast<SCCOL>(nFirstCol), static_cast<SCROW>(nFirstRow), GetCurrScTab() ) ); - pFormConv->Convert(pErgebnis, maStrm, nFormLen, true, FT_CellFormula); + pFormConv->Convert(pErgebnis, maStrm, nFormLen, true); SAL_WARN_IF(!pErgebnis, "sc", "*ImportExcel::Array25(): ScTokenArray is NULL!"); } @@ -1039,7 +1039,7 @@ void ImportExcel::Array34() pFormConv->Reset( ScAddress( static_cast<SCCOL>(nFirstCol), static_cast<SCROW>(nFirstRow), GetCurrScTab() ) ); - pFormConv->Convert( pErgebnis, maStrm, nFormLen, true, FT_CellFormula); + pFormConv->Convert( pErgebnis, maStrm, nFormLen, true ); SAL_WARN_IF(!pErgebnis, "sc", "+ImportExcel::Array34(): ScTokenArray is NULL!"); } diff --git a/sc/source/filter/excel/xepivotxml.cxx b/sc/source/filter/excel/xepivotxml.cxx index 52de28cd6a82..d3bd613aa831 100644 --- a/sc/source/filter/excel/xepivotxml.cxx +++ b/sc/source/filter/excel/xepivotxml.cxx @@ -379,8 +379,7 @@ void XclExpXmlPivotTables::SaveXml( XclExpXmlStream& rStrm ) XclXmlUtils::GetStreamName(NULL, "../pivotTables/pivotTable", nPivotId), pWSStrm->getOutputStream(), CREATE_XL_CONTENT_TYPE("pivotTable"), - CREATE_OFFICEDOC_RELATION_TYPE("pivotTable"), - NULL); + CREATE_OFFICEDOC_RELATION_TYPE("pivotTable")); rStrm.PushStream(pPivotStrm); SavePivotTableXml(rStrm, rObj, nCacheId); diff --git a/sc/source/filter/excel/xiescher.cxx b/sc/source/filter/excel/xiescher.cxx index a9c67e721fe9..f95e6e792703 100644 --- a/sc/source/filter/excel/xiescher.cxx +++ b/sc/source/filter/excel/xiescher.cxx @@ -3747,7 +3747,7 @@ void XclImpDffConverter::ProcessShContainer( SvStream& rDffStrm, const DffRecord and the returned group object contains them all. ImportObj() calls the virtual functions ProcessClientAnchor2() and ProcessObj() and writes the pointer to the related draw object data (OBJ record) into pDrawObj. */ - SdrObjectPtr xSdrObj( ImportObj( rDffStrm, &pDrawObj, aDummy, aDummy, 0, 0 ) ); + SdrObjectPtr xSdrObj( ImportObj( rDffStrm, &pDrawObj, aDummy, aDummy ) ); if( pDrawObj && xSdrObj ) InsertSdrObject( GetConvData().mrSdrPage, *pDrawObj, xSdrObj.release() ); rShHeader.SeekToEndOfRecord( rDffStrm ); @@ -3988,7 +3988,7 @@ void XclImpDrawing::ReadWmf( Graphic& rGraphic, const XclImpRoot&, XclImpStream& aMemStrm.Seek( STREAM_SEEK_TO_BEGIN ); // import the graphic from memory stream GDIMetaFile aGDIMetaFile; - if( ::ReadWindowMetafile( aMemStrm, aGDIMetaFile, 0 ) ) + if( ::ReadWindowMetafile( aMemStrm, aGDIMetaFile ) ) rGraphic = aGDIMetaFile; } diff --git a/sc/source/filter/excel/xilink.cxx b/sc/source/filter/excel/xilink.cxx index 33581ce02ea4..77647f50fc5a 100644 --- a/sc/source/filter/excel/xilink.cxx +++ b/sc/source/filter/excel/xilink.cxx @@ -494,7 +494,7 @@ bool XclImpExtName::CreateOleData(ScDocument& rDoc, const OUString& rUrl, ScExternalRefManager* pRefMgr = rDoc.GetExternalRefManager(); sal_uInt16 nFileId = pRefMgr->getExternalFileId(rUrl); - ScExternalRefCache::TableTypeRef xTab = pRefMgr->getCacheTable(nFileId, aSheet, true, NULL); + ScExternalRefCache::TableTypeRef xTab = pRefMgr->getCacheTable(nFileId, aSheet, true); if (!xTab) // cache table creation failed. return false; diff --git a/sc/source/filter/rtf/rtfexp.cxx b/sc/source/filter/rtf/rtfexp.cxx index 03434f302e8d..f36f24109de8 100644 --- a/sc/source/filter/rtf/rtfexp.cxx +++ b/sc/source/filter/rtf/rtfexp.cxx @@ -179,7 +179,7 @@ void ScRTFExport::WriteCell( SCTAB nTab, SCROW nRow, SCCOL nCol ) { EditEngine& rEngine = GetEditEngine(); rEngine.SetText(*pObj); - aContent = rEngine.GetText(LINEEND_LF); // LineFeed in between paragraphs! + aContent = rEngine.GetText(); // LineFeed in between paragraphs! } } break; diff --git a/sc/source/filter/xcl97/XclImpChangeTrack.cxx b/sc/source/filter/xcl97/XclImpChangeTrack.cxx index 0dd38ebeb36c..06c41e0bd473 100644 --- a/sc/source/filter/xcl97/XclImpChangeTrack.cxx +++ b/sc/source/filter/xcl97/XclImpChangeTrack.cxx @@ -211,7 +211,7 @@ void XclImpChangeTrack::ReadFormula( ScTokenArray*& rpTokenArray, const ScAddres // read the formula, 3D tab refs from extended data const ScTokenArray* pArray = NULL; aFmlConv.Reset( rPosition ); - bool bOK = (aFmlConv.Convert( pArray, aFmlaStrm, nFmlSize, false, FT_CellFormula) == ConvOK); // JEG : Check This + bool bOK = (aFmlConv.Convert( pArray, aFmlaStrm, nFmlSize, false ) == ConvOK); // JEG : Check This rpTokenArray = (bOK && pArray) ? new ScTokenArray( *pArray ) : NULL; pStrm->Ignore( 1 ); } diff --git a/sc/source/filter/xcl97/xcl97rec.cxx b/sc/source/filter/xcl97/xcl97rec.cxx index 904ce237c57f..70240646d7bf 100644 --- a/sc/source/filter/xcl97/xcl97rec.cxx +++ b/sc/source/filter/xcl97/xcl97rec.cxx @@ -892,8 +892,7 @@ void XclObjOle::WriteSubRecs( XclExpStream& rStrm ) sal_uInt32 nPictureId = sal_uInt32(sal_uIntPtr(this) >> 2); sprintf( aBuf, "%08X", static_cast< unsigned int >( nPictureId ) ); aStorageName += OUString::createFromAscii(aBuf); - tools::SvRef<SotStorage> xOleStg = pRootStorage->OpenSotStorage( aStorageName, - STREAM_READWRITE| StreamMode::SHARE_DENYALL ); + tools::SvRef<SotStorage> xOleStg = pRootStorage->OpenSotStorage( aStorageName ); if( xOleStg.Is() ) { uno::Reference < embed::XEmbeddedObject > xObj( static_cast<const SdrOle2Obj&>(rOleObj).GetObjRef() ); diff --git a/sc/source/filter/xml/xmlbodyi.cxx b/sc/source/filter/xml/xmlbodyi.cxx index c2b4b00f1ada..a8db60e04e09 100644 --- a/sc/source/filter/xml/xmlbodyi.cxx +++ b/sc/source/filter/xml/xmlbodyi.cxx @@ -87,7 +87,7 @@ ScXMLBodyContext::ScXMLBodyContext( ScXMLImport& rImport, // In case there was a micro version, e.g. "1.2.3", this would // still yield major.minor, but pParsedEnd (5th parameter, not // passed here) would point before string end upon return. - double fVer = ::rtl::math::stringToDouble( aVer, '.', 0, NULL, NULL); + double fVer = ::rtl::math::stringToDouble( aVer, '.', 0 ); if (fVer < 1.2) eGrammar = formula::FormulaGrammar::GRAM_PODF; } diff --git a/sc/source/filter/xml/xmlcelli.cxx b/sc/source/filter/xml/xmlcelli.cxx index 601d71e559c5..3612f38c2ace 100644 --- a/sc/source/filter/xml/xmlcelli.cxx +++ b/sc/source/filter/xml/xmlcelli.cxx @@ -1306,7 +1306,7 @@ OUString getOutputString( ScDocument* pDoc, const ScAddress& aCellPos ) { EditEngine& rEngine = pDoc->GetEditEngine(); rEngine.SetText(*pData); - return rEngine.GetText(LINEEND_LF); + return rEngine.GetText(); } // also don't format EditCells per NumberFormatter } diff --git a/sc/source/filter/xml/xmlexprt.cxx b/sc/source/filter/xml/xmlexprt.cxx index 0853d35b61e1..4b47706f5279 100644 --- a/sc/source/filter/xml/xmlexprt.cxx +++ b/sc/source/filter/xml/xmlexprt.cxx @@ -232,7 +232,7 @@ OUString lcl_GetFormattedString( ScDocument* pDoc, const ScAddress& rPos ) EditEngine& rEngine = pDoc->GetEditEngine(); rEngine.SetText(*pData); - return rEngine.GetText(LINEEND_LF); + return rEngine.GetText(); } break; default: @@ -3584,7 +3584,7 @@ void ScXMLExport::WriteAnnotation(ScMyCell& rMyCell) { Reference<drawing::XShape> xShape( pNoteCaption->getUnoShape(), uno::UNO_QUERY ); if (xShape.is()) - GetShapeExport()->exportShape(xShape, SEF_DEFAULT|XMLShapeExportFlags::ANNOTATION, NULL); + GetShapeExport()->exportShape(xShape, SEF_DEFAULT|XMLShapeExportFlags::ANNOTATION); } pCurrentCell = NULL; diff --git a/sc/source/ui/Accessibility/AccessibleCellBase.cxx b/sc/source/ui/Accessibility/AccessibleCellBase.cxx index ece8b75245ca..8cb2ab1b5bbc 100644 --- a/sc/source/ui/Accessibility/AccessibleCellBase.cxx +++ b/sc/source/ui/Accessibility/AccessibleCellBase.cxx @@ -219,7 +219,7 @@ OUString SAL_CALL { // Document not needed, because only the cell address, but not the tablename is needed // always us OOO notation - return maCellAddress.Format(SCA_VALID, NULL); + return maCellAddress.Format(SCA_VALID); } //===== XAccessibleValue ================================================ diff --git a/sc/source/ui/Accessibility/AccessibleDocument.cxx b/sc/source/ui/Accessibility/AccessibleDocument.cxx index d2776a3581cb..6efa9389e3ff 100644 --- a/sc/source/ui/Accessibility/AccessibleDocument.cxx +++ b/sc/source/ui/Accessibility/AccessibleDocument.cxx @@ -2298,7 +2298,7 @@ OUString ScAccessibleDocument::GetCurrentCellName() const if (mpViewShell) { // Document not needed, because only the cell address, but not the tablename is needed - OUString sAddress(mpViewShell->GetViewData().GetCurPos().Format(SCA_VALID, NULL)); + OUString sAddress(mpViewShell->GetViewData().GetCurPos().Format(SCA_VALID)); sName = sName.replaceFirst("%1", sAddress); } return sName; diff --git a/sc/source/ui/Accessibility/AccessibleDocumentPagePreview.cxx b/sc/source/ui/Accessibility/AccessibleDocumentPagePreview.cxx index 2ad40efd65fe..a2c06dc0049e 100644 --- a/sc/source/ui/Accessibility/AccessibleDocumentPagePreview.cxx +++ b/sc/source/ui/Accessibility/AccessibleDocumentPagePreview.cxx @@ -174,7 +174,7 @@ sal_Int32 ScNotesChildren::AddNotes(const ScPreviewLocationData& rData, const Re if (bMark) { // Document not needed, because only the cell address, but not the tablename is needed - aNote.maNoteText = aNote.maNoteCell.Format(SCA_VALID, NULL); + aNote.maNoteText = aNote.maNoteCell.Format(SCA_VALID); } else { @@ -346,7 +346,7 @@ sal_Int32 ScNotesChildren::CheckChanges(const ScPreviewLocationData& rData, if (bMark) { // Document not needed, because only the cell address, but not the tablename is needed - aNote.maNoteText = aNote.maNoteCell.Format(SCA_VALID, NULL); + aNote.maNoteText = aNote.maNoteCell.Format(SCA_VALID); } else { diff --git a/sc/source/ui/app/drwtrans.cxx b/sc/source/ui/app/drwtrans.cxx index 4cd8e87c5b3b..53bcf60cf887 100644 --- a/sc/source/ui/app/drwtrans.cxx +++ b/sc/source/ui/app/drwtrans.cxx @@ -722,7 +722,7 @@ void ScDrawTransferObj::InitDocShell() ScDocShell* pDocSh = new ScDocShell; aDocShellRef = pDocSh; // ref must be there before InitNew - pDocSh->DoInitNew(NULL); + pDocSh->DoInitNew(); ScDocument& rDestDoc = pDocSh->GetDocument(); rDestDoc.InitDrawLayer( pDocSh ); diff --git a/sc/source/ui/app/seltrans.cxx b/sc/source/ui/app/seltrans.cxx index 0e199354d94f..488ae52c644e 100644 --- a/sc/source/ui/app/seltrans.cxx +++ b/sc/source/ui/app/seltrans.cxx @@ -275,7 +275,7 @@ void ScSelectionTransferObj::CreateCellData() if ( pDocSh->GetDocument().HasOLEObjectsInArea( aSelRange, &aNewMark ) ) { aDragShellRef = new ScDocShell; // DocShell needs a Ref immediately - aDragShellRef->DoInitNew(NULL); + aDragShellRef->DoInitNew(); } ScDrawLayer::SetGlobalDrawPersist(aDragShellRef); @@ -333,7 +333,7 @@ void ScSelectionTransferObj::CreateDrawData() if (bAnyOle) { aDragShellRef = new ScDocShell; // Without Ref the DocShell does not live - aDragShellRef->DoInitNew(NULL); + aDragShellRef->DoInitNew(); } ScDrawLayer::SetGlobalDrawPersist(aDragShellRef); diff --git a/sc/source/ui/app/transobj.cxx b/sc/source/ui/app/transobj.cxx index 23b4db51b659..017d68b3b283 100644 --- a/sc/source/ui/app/transobj.cxx +++ b/sc/source/ui/app/transobj.cxx @@ -590,7 +590,7 @@ void ScTransferObj::InitDocShell(bool bLimitToPageSize) ScDocShell* pDocSh = new ScDocShell; aDocShellRef = pDocSh; // ref must be there before InitNew - pDocSh->DoInitNew(NULL); + pDocSh->DoInitNew(); ScDocument& rDestDoc = pDocSh->GetDocument(); ScMarkData aDestMark; @@ -737,7 +737,7 @@ SfxObjectShell* ScTransferObj::SetDrawClipDoc( bool bAnyOle ) { ScGlobal::pDrawClipDocShellRef = new ScDocShellRef(new ScDocShell(SfxModelFlags::EMBEDDED_OBJECT | SfxModelFlags::DISABLE_EMBEDDED_SCRIPTS)); // there must be a ref - (*ScGlobal::pDrawClipDocShellRef)->DoInitNew(NULL); + (*ScGlobal::pDrawClipDocShellRef)->DoInitNew(); return *ScGlobal::pDrawClipDocShellRef; } else diff --git a/sc/source/ui/cctrl/checklistmenu.cxx b/sc/source/ui/cctrl/checklistmenu.cxx index ede2a3a2e932..594cf11fd1dd 100644 --- a/sc/source/ui/cctrl/checklistmenu.cxx +++ b/sc/source/ui/cctrl/checklistmenu.cxx @@ -1551,8 +1551,7 @@ void ScCheckListBox::ShowCheckEntry( const OUString& sName, SvTreeListEntry* pPa if ( !pEntry ) { pEntry = InsertEntry( - sName, nullptr, false, TREELIST_APPEND, nullptr, - SvLBoxButtonKind_enabledCheckbox); + sName); SetCheckButtonState( pEntry, bCheck ? SV_BUTTON_CHECKED : SV_BUTTON_UNCHECKED); @@ -1644,8 +1643,7 @@ void ScCheckListMenuWindow::initMembers() if (aLabel.isEmpty()) aLabel = ScGlobal::GetRscString(STR_EMPTYDATA); SvTreeListEntry* pEntry = maChecks->InsertEntry( - aLabel, nullptr, false, TREELIST_APPEND, nullptr, - SvLBoxButtonKind_enabledCheckbox); + aLabel); maChecks->SetCheckButtonState( pEntry, maMembers[i].mbVisible ? SV_BUTTON_CHECKED : SV_BUTTON_UNCHECKED); diff --git a/sc/source/ui/docshell/docfunc.cxx b/sc/source/ui/docshell/docfunc.cxx index 495982851949..86422aedffb4 100644 --- a/sc/source/ui/docshell/docfunc.cxx +++ b/sc/source/ui/docshell/docfunc.cxx @@ -2605,7 +2605,7 @@ bool ScDocFunc::MoveBlock( const ScRange& rSource, const ScAddress& rDestPos, if ( rDoc.HasOLEObjectsInArea( rSource ) ) { aDragShellRef = new ScDocShell; // DocShell needs a Ref immediately - aDragShellRef->DoInitNew(NULL); + aDragShellRef->DoInitNew(); } ScDrawLayer::SetGlobalDrawPersist(aDragShellRef); @@ -3364,7 +3364,7 @@ static sal_uInt16 lcl_GetOptimalColWidth( ScDocShell& rDocShell, SCCOL nCol, SCT ScDocument& rDoc = rDocShell.GetDocument(); Fraction aOne(1,1); sal_uInt16 nTwips = rDoc.GetOptimalColWidth( nCol, nTab, pDev, nPPTX, nPPTY, aOne, aOne, - bFormula, NULL ); + bFormula ); return nTwips; } diff --git a/sc/source/ui/docshell/docsh.cxx b/sc/source/ui/docshell/docsh.cxx index 487c89a7930f..f35d181fe4e7 100644 --- a/sc/source/ui/docshell/docsh.cxx +++ b/sc/source/ui/docshell/docsh.cxx @@ -597,7 +597,7 @@ bool ScDocShell::Load( SfxMedium& rMedium ) aDocument.InvalidateTableArea(); bIsEmpty = false; - FinishedLoading( SfxLoadedFlags::ALL ); + FinishedLoading(); return bRet; } @@ -1510,7 +1510,7 @@ bool ScDocShell::ConvertFrom( SfxMedium& rMedium ) aUpdater.update(); } } - FinishedLoading( SfxLoadedFlags::ALL ); + FinishedLoading(); // invalidate eventually temporary table areas if ( bRet ) @@ -1555,7 +1555,7 @@ bool ScDocShell::LoadExternal( SfxMedium& rMed ) return false; } - FinishedLoading(SfxLoadedFlags::ALL); + FinishedLoading(); return true; } diff --git a/sc/source/ui/docshell/impex.cxx b/sc/source/ui/docshell/impex.cxx index fded9aca1f6b..ef8229fb27f6 100644 --- a/sc/source/ui/docshell/impex.cxx +++ b/sc/source/ui/docshell/impex.cxx @@ -1151,7 +1151,7 @@ static bool lcl_PutString( OUString aT( &cDec, 1); aT += rStr.copy( nStart[6], nEnd[6]+1-nStart[6]); rtl_math_ConversionStatus eStatus; - double fV = rtl::math::stringToDouble( aT, cDec, 0, &eStatus, 0); + double fV = rtl::math::stringToDouble( aT, cDec, 0, &eStatus ); if (eStatus == rtl_math_ConversionStatus_Ok) nMilli = (sal_Int16) (1000.0 * fV + 0.5); } diff --git a/sc/source/ui/drawfunc/futext.cxx b/sc/source/ui/drawfunc/futext.cxx index 7e3582439f8d..fa9c4b4844b5 100644 --- a/sc/source/ui/drawfunc/futext.cxx +++ b/sc/source/ui/drawfunc/futext.cxx @@ -324,7 +324,7 @@ bool FuText::MouseButtonDown(const MouseEvent& rMEvt) // also adjusted ) Point aGridOff = CurrentGridSyncOffsetAndPos( aMDPos ); - bool bRet = pView->BegCreateObj(aMDPos, nullptr); + bool bRet = pView->BegCreateObj(aMDPos); if ( bRet ) pView->GetCreateObj()->SetGridOffset( aGridOff ); } diff --git a/sc/source/ui/miscdlgs/sharedocdlg.cxx b/sc/source/ui/miscdlgs/sharedocdlg.cxx index b20cd3b88a03..b8f850f8ea7d 100644 --- a/sc/source/ui/miscdlgs/sharedocdlg.cxx +++ b/sc/source/ui/miscdlgs/sharedocdlg.cxx @@ -186,20 +186,20 @@ void ScShareDocumentDlg::UpdateView() aString += "\t"; aString += formatTime(aDateTime, *ScGlobal::pLocaleData); - m_pLbUsers->InsertEntry( aString, NULL ); + m_pLbUsers->InsertEntry( aString ); } } } else { - m_pLbUsers->InsertEntry( m_aStrNoUserData, NULL ); + m_pLbUsers->InsertEntry( m_aStrNoUserData ); } } catch ( uno::Exception& ) { OSL_FAIL( "ScShareDocumentDlg::UpdateView(): caught exception\n" ); m_pLbUsers->Clear(); - m_pLbUsers->InsertEntry( m_aStrNoUserData, NULL ); + m_pLbUsers->InsertEntry( m_aStrNoUserData ); } } else @@ -239,7 +239,7 @@ void ScShareDocumentDlg::UpdateView() aString += " "; aString += ScGlobal::pLocaleData->getTime( aDateTime, false ); - m_pLbUsers->InsertEntry( aString, NULL ); + m_pLbUsers->InsertEntry( aString ); } } diff --git a/sc/source/ui/miscdlgs/solveroptions.cxx b/sc/source/ui/miscdlgs/solveroptions.cxx index 3482786ae339..bd7965b285cf 100644 --- a/sc/source/ui/miscdlgs/solveroptions.cxx +++ b/sc/source/ui/miscdlgs/solveroptions.cxx @@ -472,7 +472,7 @@ double ScSolverValueDialog::GetValue() const double fValue = rtl::math::stringToDouble( aInput, pLocaleData->getNumDecimalSep()[0], pLocaleData->getNumThousandSep()[0], - &eStatus, NULL ); + &eStatus ); return fValue; } diff --git a/sc/source/ui/namedlg/namemgrtable.cxx b/sc/source/ui/namedlg/namemgrtable.cxx index 4f0d33adc2c2..770fa33555ed 100644 --- a/sc/source/ui/namedlg/namemgrtable.cxx +++ b/sc/source/ui/namedlg/namemgrtable.cxx @@ -293,10 +293,10 @@ IMPL_LINK_NOARG_TYPED(ScRangeManagerTable, HeaderEndDragHdl, HeaderBar*, void) rHeaderBar.SetItemSize(ITEMID_RANGE, nItemRangeSize); rHeaderBar.SetItemSize(ITEMID_SCOPE, nItemScopeSize); - SetTab(0, 0, MAP_APPFONT ); - SetTab(1, PixelToLogic( aSz, MapMode(MAP_APPFONT) ).Width(), MAP_APPFONT ); + SetTab(0, 0); + SetTab(1, PixelToLogic( aSz, MapMode(MAP_APPFONT) ).Width() ); aSz.Width() += nItemRangeSize; - SetTab(2, PixelToLogic( aSz, MapMode(MAP_APPFONT) ).Width(), MAP_APPFONT ); + SetTab(2, PixelToLogic( aSz, MapMode(MAP_APPFONT) ).Width() ); } IMPL_LINK_NOARG_TYPED(ScRangeManagerTable, ScrollHdl, SvTreeListBox*, void) diff --git a/sc/source/ui/optdlg/calcoptionsdlg.cxx b/sc/source/ui/optdlg/calcoptionsdlg.cxx index 862a59367c78..19697c4db490 100644 --- a/sc/source/ui/optdlg/calcoptionsdlg.cxx +++ b/sc/source/ui/optdlg/calcoptionsdlg.cxx @@ -538,7 +538,7 @@ struct Round : Area "," + ScAddress(1,1+nRow,nTab).Format(SCA_VALID_COL|SCA_VALID_ROW) + ")"); - pDoc->SetValue(ScAddress(3,1+nRow,nTab), ::rtl::math::round(nX, (short) nN, rtl_math_RoundingMode_Corrected)); + pDoc->SetValue(ScAddress(3,1+nRow,nTab), ::rtl::math::round(nX, (short) nN)); pDoc->SetString(ScAddress(4,1+nRow,nTab), "=IF(ABS(" + ScAddress(2,1+nRow,nTab).Format(SCA_VALID_COL|SCA_VALID_ROW) + diff --git a/sc/source/ui/unoobj/cellsuno.cxx b/sc/source/ui/unoobj/cellsuno.cxx index f11d9edccc60..a42c40740237 100644 --- a/sc/source/ui/unoobj/cellsuno.cxx +++ b/sc/source/ui/unoobj/cellsuno.cxx @@ -1361,7 +1361,7 @@ static OUString lcl_GetInputString( ScDocument& rDoc, const ScAddress& rPos, boo { EditEngine& rEngine = rDoc.GetEditEngine(); rEngine.SetText(*pData); - aVal = rEngine.GetText(LINEEND_LF); + aVal = rEngine.GetText(); } } else @@ -3940,7 +3940,7 @@ uno::Reference<container::XIndexAccess> SAL_CALL ScCellRangesBase::findAll( SCROW nRow = 0; SCTAB nTab = 0; bool bFound = rDoc.SearchAndReplace( - *pSearchItem, nCol, nRow, nTab, aMark, aMatchedRanges, aDummyUndo, NULL); + *pSearchItem, nCol, nRow, nTab, aMark, aMatchedRanges, aDummyUndo); if (bFound) { // bei findAll immer CellRanges, egal wieviel gefunden wurde @@ -3986,7 +3986,7 @@ uno::Reference<uno::XInterface> ScCellRangesBase::Find_Impl( OUString aDummyUndo; ScRangeList aMatchedRanges; bool bFound = rDoc.SearchAndReplace( - *pSearchItem, nCol, nRow, nTab, aMark, aMatchedRanges, aDummyUndo, NULL); + *pSearchItem, nCol, nRow, nTab, aMark, aMatchedRanges, aDummyUndo); if (bFound) { ScAddress aFoundPos( nCol, nRow, nTab ); @@ -4987,7 +4987,7 @@ uno::Reference<table::XCellRange> ScCellRangeObj::getCellRangeByName( else { ScRangeUtil aRangeUtil; - if ( ScRangeUtil::MakeRangeFromName( aString, &rDoc, nTab, aCellRange, RUTL_NAMES ) || + if ( ScRangeUtil::MakeRangeFromName( aString, &rDoc, nTab, aCellRange ) || ScRangeUtil::MakeRangeFromName( aString, &rDoc, nTab, aCellRange, RUTL_DBASE ) ) bFound = true; } diff --git a/sc/source/ui/unoobj/chart2uno.cxx b/sc/source/ui/unoobj/chart2uno.cxx index d31c882681e9..5542341923c4 100644 --- a/sc/source/ui/unoobj/chart2uno.cxx +++ b/sc/source/ui/unoobj/chart2uno.cxx @@ -2680,7 +2680,7 @@ sal_Int32 ScChart2DataSequence::FillCacheFromExternalRef(const ScTokenRef& pToke pRefMgr->addLinkListener(nFileId, pExtRefListener); pExtRefListener->addFileId(nFileId); - ScExternalRefCache::TableTypeRef pTable = pRefMgr->getCacheTable(nFileId, aTabName, false, nullptr); + ScExternalRefCache::TableTypeRef pTable = pRefMgr->getCacheTable(nFileId, aTabName, false); sal_Int32 nDataCount = 0; for (FormulaToken* p = pArray->First(); p; p = pArray->Next()) { @@ -3162,7 +3162,7 @@ public: OUString aString = ScGlobal::GetRscString(STR_COLUMN); aString += " "; ScAddress aPos( nCol, 0, 0 ); - OUString aColStr(aPos.Format(SCA_VALID_COL, nullptr)); + OUString aColStr(aPos.Format(SCA_VALID_COL)); aString += aColStr; pArr[mnCount] = aString; } diff --git a/sc/source/ui/unoobj/docuno.cxx b/sc/source/ui/unoobj/docuno.cxx index e920c4925825..3d3e7b7ee65a 100644 --- a/sc/source/ui/unoobj/docuno.cxx +++ b/sc/source/ui/unoobj/docuno.cxx @@ -434,7 +434,7 @@ SfxObjectShell* ScModelObj::GetEmbeddedObject() const void ScModelObj::UpdateAllRowHeights() { if (pDocShell) - pDocShell->UpdateAllRowHeights(NULL); + pDocShell->UpdateAllRowHeights(); } void ScModelObj::BeforeXMLLoading() @@ -1108,7 +1108,7 @@ static bool lcl_ParseTarget( const OUString& rTarget, ScRange& rTargetRange, Rec rTargetRange = aAddress; bRangeValid = true; // cell reference } - else if ( ScRangeUtil::MakeRangeFromName( rTarget, pDoc, nSourceTab, rTargetRange, RUTL_NAMES ) || + else if ( ScRangeUtil::MakeRangeFromName( rTarget, pDoc, nSourceTab, rTargetRange ) || ScRangeUtil::MakeRangeFromName( rTarget, pDoc, nSourceTab, rTargetRange, RUTL_DBASE ) ) { bRangeValid = true; // named range or database range diff --git a/sc/source/ui/vba/vbafont.cxx b/sc/source/ui/vba/vbafont.cxx index 0a3935593772..3af7792cb81f 100644 --- a/sc/source/ui/vba/vbafont.cxx +++ b/sc/source/ui/vba/vbafont.cxx @@ -220,7 +220,7 @@ uno::Any SAL_CALL ScVbaFont::getSize() throw ( uno::RuntimeException, std::exception ) { if ( GetDataSet() ) - if ( GetDataSet()->GetItemState( ATTR_FONT_HEIGHT, true, NULL) == SfxItemState::DONTCARE ) + if ( GetDataSet()->GetItemState( ATTR_FONT_HEIGHT) == SfxItemState::DONTCARE ) return aNULL(); return ScVbaFont_BASE::getSize(); } @@ -246,7 +246,7 @@ uno::Any SAL_CALL ScVbaFont::getColorIndex() throw ( uno::RuntimeException, std::exception ) { if ( GetDataSet() ) - if ( GetDataSet()->GetItemState( ATTR_FONT_COLOR, true, NULL) == SfxItemState::DONTCARE ) + if ( GetDataSet()->GetItemState( ATTR_FONT_COLOR) == SfxItemState::DONTCARE ) return aNULL(); return ScVbaFont_BASE::getColorIndex(); } @@ -337,7 +337,7 @@ uno::Any SAL_CALL ScVbaFont::getBold() throw ( uno::RuntimeException, std::exception ) { if ( GetDataSet() ) - if ( GetDataSet()->GetItemState( ATTR_FONT_WEIGHT, true, NULL) == SfxItemState::DONTCARE ) + if ( GetDataSet()->GetItemState( ATTR_FONT_WEIGHT) == SfxItemState::DONTCARE ) return aNULL(); return ScVbaFont_BASE::getBold(); } @@ -380,7 +380,7 @@ uno::Any SAL_CALL ScVbaFont::getUnderline() throw ( uno::RuntimeException, std::exception ) { if ( GetDataSet() ) - if ( GetDataSet()->GetItemState( ATTR_FONT_UNDERLINE, true, NULL) == SfxItemState::DONTCARE ) + if ( GetDataSet()->GetItemState( ATTR_FONT_UNDERLINE) == SfxItemState::DONTCARE ) return aNULL(); sal_Int32 nValue = awt::FontUnderline::NONE; @@ -407,7 +407,7 @@ uno::Any SAL_CALL ScVbaFont::getStrikethrough() throw ( uno::RuntimeException, std::exception ) { if ( GetDataSet() ) - if ( GetDataSet()->GetItemState( ATTR_FONT_CROSSEDOUT, true, NULL) == SfxItemState::DONTCARE ) + if ( GetDataSet()->GetItemState( ATTR_FONT_CROSSEDOUT) == SfxItemState::DONTCARE ) return aNULL(); return ScVbaFont_BASE::getStrikethrough(); } @@ -416,7 +416,7 @@ uno::Any SAL_CALL ScVbaFont::getShadow() throw (uno::RuntimeException, std::exception) { if ( GetDataSet() ) - if ( GetDataSet()->GetItemState( ATTR_FONT_SHADOWED, true, NULL) == SfxItemState::DONTCARE ) + if ( GetDataSet()->GetItemState( ATTR_FONT_SHADOWED) == SfxItemState::DONTCARE ) return aNULL(); return ScVbaFont_BASE::getShadow(); } @@ -425,7 +425,7 @@ uno::Any SAL_CALL ScVbaFont::getItalic() throw ( uno::RuntimeException, std::exception ) { if ( GetDataSet() ) - if ( GetDataSet()->GetItemState( ATTR_FONT_POSTURE, true, NULL) == SfxItemState::DONTCARE ) + if ( GetDataSet()->GetItemState( ATTR_FONT_POSTURE) == SfxItemState::DONTCARE ) return aNULL(); return ScVbaFont_BASE::getItalic(); @@ -435,7 +435,7 @@ uno::Any SAL_CALL ScVbaFont::getName() throw ( uno::RuntimeException, std::exception ) { if ( GetDataSet() ) - if ( GetDataSet()->GetItemState( ATTR_FONT, true, NULL) == SfxItemState::DONTCARE ) + if ( GetDataSet()->GetItemState( ATTR_FONT) == SfxItemState::DONTCARE ) return aNULL(); return ScVbaFont_BASE::getName(); } @@ -458,7 +458,7 @@ uno::Any SAL_CALL ScVbaFont::getOutlineFont() throw (uno::RuntimeException, std::exception) { if ( GetDataSet() ) - if ( GetDataSet()->GetItemState( ATTR_FONT_CONTOUR, true, NULL) == SfxItemState::DONTCARE ) + if ( GetDataSet()->GetItemState( ATTR_FONT_CONTOUR) == SfxItemState::DONTCARE ) return aNULL(); return mxFont->getPropertyValue("CharContoured"); } diff --git a/sc/source/ui/vba/vbaformat.cxx b/sc/source/ui/vba/vbaformat.cxx index 1896a12b521c..342b0ce2cc1d 100644 --- a/sc/source/ui/vba/vbaformat.cxx +++ b/sc/source/ui/vba/vbaformat.cxx @@ -565,7 +565,7 @@ ScVbaFormat< Ifc... >::getLocked( ) throw (script::BasicErrorException, uno::Ru if ( pDataSet ) { const ScProtectionAttr& rProtAttr = static_cast<const ScProtectionAttr &>( pDataSet->Get(ATTR_PROTECTION) ); - SfxItemState eState = pDataSet->GetItemState(ATTR_PROTECTION, true, NULL); + SfxItemState eState = pDataSet->GetItemState(ATTR_PROTECTION); if(eState != SfxItemState::DONTCARE) aCellProtection = uno::makeAny(rProtAttr.GetProtection()); } @@ -598,7 +598,7 @@ ScVbaFormat< Ifc... >::getFormulaHidden( ) throw (script::BasicErrorException, if ( pDataSet ) { const ScProtectionAttr& rProtAttr = static_cast<const ScProtectionAttr &>( pDataSet->Get(ATTR_PROTECTION) ); - SfxItemState eState = pDataSet->GetItemState(ATTR_PROTECTION, true, NULL); + SfxItemState eState = pDataSet->GetItemState(ATTR_PROTECTION); if(eState != SfxItemState::DONTCARE) aBoolRet = uno::makeAny(rProtAttr.GetHideFormula()); } diff --git a/sc/source/ui/vba/vbarange.cxx b/sc/source/ui/vba/vbarange.cxx index f8472f4b25dc..afa3ba625232 100644 --- a/sc/source/ui/vba/vbarange.cxx +++ b/sc/source/ui/vba/vbarange.cxx @@ -541,7 +541,7 @@ public: { SfxItemSet* pDataSet = excel::ScVbaCellRangeAccess::GetDataSet( pUnoCellRange ); - SfxItemState eState = pDataSet->GetItemState( ATTR_VALUE_FORMAT, true, NULL); + SfxItemState eState = pDataSet->GetItemState( ATTR_VALUE_FORMAT); // one of the cells in the range is not like the other ;-) // so return a zero length format to indicate that if ( eState == SfxItemState::DONTCARE ) @@ -2659,7 +2659,7 @@ ScVbaRange::getWrapText() throw (script::BasicErrorException, uno::RuntimeExcept SfxItemSet* pDataSet = getCurrentDataSet(); - SfxItemState eState = pDataSet->GetItemState( ATTR_LINEBREAK, true, NULL); + SfxItemState eState = pDataSet->GetItemState( ATTR_LINEBREAK); if ( eState == SfxItemState::DONTCARE ) return aNULL(); diff --git a/sc/source/ui/view/cellsh1.cxx b/sc/source/ui/view/cellsh1.cxx index 3244d4596e5d..821255ee4c1d 100644 --- a/sc/source/ui/view/cellsh1.cxx +++ b/sc/source/ui/view/cellsh1.cxx @@ -1865,7 +1865,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq ) } else // CANCEL { - pScMod->ActivateInputWindow( nullptr ); + pScMod->ActivateInputWindow(); } rReq.Ignore(); // only SID_ENTER_STRING is recorded } diff --git a/sc/source/ui/view/cellsh2.cxx b/sc/source/ui/view/cellsh2.cxx index fb3e6b796292..3000b759b54e 100644 --- a/sc/source/ui/view/cellsh2.cxx +++ b/sc/source/ui/view/cellsh2.cxx @@ -971,7 +971,7 @@ void ScCellShell::ExecuteDB( SfxRequest& rReq ) SvMemoryStream aStream; aStream.SetStreamCharSet( RTL_TEXTENCODING_UNICODE ); ScImportExport::SetNoEndianSwap( aStream ); - aExport.ExportStream( aStream, OUString(), SotClipboardFormatId::STRING ); + aExport.ExportStream( aStream, OUString() ); ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create(); OSL_ENSURE( pFact, "ScCellShell::ExecuteDB: SID_TEXT_TO_COLUMNS - pFact is null!" ); @@ -996,7 +996,7 @@ void ScCellShell::ExecuteDB( SfxRequest& rReq ) aImport.SetImportBroadcast( true ); aImport.SetOverwriting( true ); aStream.Seek( 0 ); - aImport.ImportStream( aStream, OUString(), SotClipboardFormatId::STRING ); + aImport.ImportStream( aStream, OUString() ); pDocSh->GetUndoManager()->LeaveListAction(); } diff --git a/sc/source/ui/view/drawvie4.cxx b/sc/source/ui/view/drawvie4.cxx index acbe5defcc40..26b90adcd676 100644 --- a/sc/source/ui/view/drawvie4.cxx +++ b/sc/source/ui/view/drawvie4.cxx @@ -109,7 +109,7 @@ bool ScDrawView::BeginDrag( vcl::Window* pWindow, const Point& rStartPos ) if (bAnyOle) { aDragShellRef = new ScDocShell; // DocShell needs a Ref immediately - aDragShellRef->DoInitNew(NULL); + aDragShellRef->DoInitNew(); } ScDrawLayer::SetGlobalDrawPersist(aDragShellRef); SdrModel* pModel = GetMarkedObjModel(); diff --git a/sc/source/ui/view/gridwin4.cxx b/sc/source/ui/view/gridwin4.cxx index 51e4b1923d0d..51ae5fdc8397 100644 --- a/sc/source/ui/view/gridwin4.cxx +++ b/sc/source/ui/view/gridwin4.cxx @@ -975,7 +975,7 @@ void ScGridWindow::PaintTile( VirtualDevice& rDevice, double fPPTY = pViewData->GetPPTY(); ScTableInfo aTabInfo; - pDoc->FillInfo(aTabInfo, nStartCol, nStartRow, nEndCol, nEndRow, nTab, fPPTX, fPPTY, false, false, NULL); + pDoc->FillInfo(aTabInfo, nStartCol, nStartRow, nEndCol, nEndRow, nTab, fPPTX, fPPTY, false, false); ScOutputData aOutputData(&rDevice, OUTTYPE_WINDOW, aTabInfo, pDoc, nTab, -fTilePosXPixel, -fTilePosYPixel, nStartCol, nStartRow, nEndCol, nEndRow, diff --git a/sc/source/ui/view/gridwin5.cxx b/sc/source/ui/view/gridwin5.cxx index e7678b7c025a..947d20b07ad7 100644 --- a/sc/source/ui/view/gridwin5.cxx +++ b/sc/source/ui/view/gridwin5.cxx @@ -377,7 +377,7 @@ void ScGridWindow::RequestHelp(const HelpEvent& rHEvt) if ( aHelpText.isEmpty() ) // Text-URL { OUString aUrl; - if ( GetEditUrl( aPosPixel, NULL, &aUrl, NULL ) ) + if ( GetEditUrl( aPosPixel, NULL, &aUrl ) ) { aHelpText = INetURLObject::decode( aUrl, INetURLObject::DECODE_UNAMBIGUOUS ); diff --git a/sc/source/ui/view/printfun.cxx b/sc/source/ui/view/printfun.cxx index 74f72158b7d2..4e9f6c4c9af1 100644 --- a/sc/source/ui/view/printfun.cxx +++ b/sc/source/ui/view/printfun.cxx @@ -2929,7 +2929,7 @@ Size ScPrintFunc::GetDocPageSize() void ScPrintFunc::ResetBreaks( SCTAB nTab ) // Set Breaks correctly for view { pDoc->SetPageSize( nTab, GetDocPageSize() ); - pDoc->UpdatePageBreaks( nTab, NULL ); + pDoc->UpdatePageBreaks( nTab ); } static void lcl_SetHidden( ScDocument* pDoc, SCTAB nPrintTab, ScPageRowEntry& rPageRowEntry, @@ -2976,7 +2976,7 @@ void ScPrintFunc::CalcPages() // calculates aPageRect and pages fr } else { - pDoc->UpdatePageBreaks( nPrintTab, NULL ); // else, end is marked + pDoc->UpdatePageBreaks( nPrintTab ); // else, end is marked } const size_t nRealCnt = nEndRow-nStartRow+1; diff --git a/sc/source/ui/view/viewfun2.cxx b/sc/source/ui/view/viewfun2.cxx index eec6a8a594b9..7fd92aa5bdc2 100644 --- a/sc/source/ui/view/viewfun2.cxx +++ b/sc/source/ui/view/viewfun2.cxx @@ -1895,7 +1895,7 @@ bool ScViewFunc::SearchAndReplace( const SvxSearchItem* pSearchItem, ScRangeList aMatchedRanges; ScTable::UpdateSearchItemAddressForReplace( aSearchItem, nCol, nRow ); - if ( rDoc.SearchAndReplace( aSearchItem, nCol, nRow, nTab, rMark, aMatchedRanges, aUndoStr, NULL ) && + if ( rDoc.SearchAndReplace( aSearchItem, nCol, nRow, nTab, rMark, aMatchedRanges, aUndoStr ) && ( nTab == nOldTab ) && ( nCol != nOldCol || nRow != nOldRow ) ) { diff --git a/sc/source/ui/view/viewfun3.cxx b/sc/source/ui/view/viewfun3.cxx index 7eb9aa62af12..af8dbeca931e 100644 --- a/sc/source/ui/view/viewfun3.cxx +++ b/sc/source/ui/view/viewfun3.cxx @@ -682,8 +682,7 @@ void ScViewFunc::PasteFromTransferable( const uno::Reference<datatransfer::XTran return; PasteDataFormat( nFormatId, aDataHelper.GetTransferable(), - GetViewData().GetCurX(), GetViewData().GetCurY(), - NULL ); + GetViewData().GetCurX(), GetViewData().GetCurY() ); } } } @@ -911,7 +910,7 @@ bool ScViewFunc::PasteFromClip( InsertDeleteFlags nFlags, ScDocument* pClipDoc, if ( bPasteDraw ) { aTransShellRef = new ScDocShell; // DocShell needs a Ref immediately - aTransShellRef->DoInitNew(NULL); + aTransShellRef->DoInitNew(); } ScDrawLayer::SetGlobalDrawPersist(aTransShellRef); @@ -1691,7 +1690,7 @@ bool ScViewFunc::PasteFromClipToMultiRanges( { pDoc->CopyFromClip( *aRanges[i], aMark, (nFlags & ~IDF_OBJECTS), NULL, pClipDoc, - false, false, true, bSkipEmpty, NULL); + false, false, true, bSkipEmpty); } if (pMixDoc.get()) @@ -1709,7 +1708,7 @@ bool ScViewFunc::PasteFromClipToMultiRanges( { pDoc->CopyFromClip( *aRanges[i], aMark, IDF_OBJECTS, NULL, pClipDoc, - false, false, true, bSkipEmpty, NULL); + false, false, true, bSkipEmpty); } } diff --git a/sc/source/ui/view/viewfun5.cxx b/sc/source/ui/view/viewfun5.cxx index dd8bb7e7c9e3..1891ec07ec34 100644 --- a/sc/source/ui/view/viewfun5.cxx +++ b/sc/source/ui/view/viewfun5.cxx @@ -491,7 +491,7 @@ bool ScViewFunc::PasteDataFormat( SotClipboardFormatId nFormatId, OUString aPath = aPathOpt.GetPalettePath(); ScDocShellRef aDragShellRef( new ScDocShell ); - aDragShellRef->DoInitNew(NULL); + aDragShellRef->DoInitNew(); std::unique_ptr<FmFormModel> pModel(new FmFormModel( aPath, NULL, aDragShellRef )); pModel->GetItemPool().FreezeIdRanges(); |