[Libreoffice-commits] core.git: sc/source
Noel Grandin
noel at peralex.com
Wed Nov 4 00:02:22 PST 2015
sc/source/core/data/dpobject.cxx | 35 ++++++----------
sc/source/core/data/dpoutput.cxx | 3 -
sc/source/core/data/dpsave.cxx | 12 ++---
sc/source/core/tool/formulaparserpool.cxx | 2
sc/source/filter/excel/xltoolbar.cxx | 2
sc/source/filter/xml/XMLCalculationSettingsContext.cxx | 18 ++++----
sc/source/filter/xml/XMLExportDDELinks.cxx | 2
sc/source/filter/xml/XMLExportDatabaseRanges.cxx | 4 -
sc/source/filter/xml/XMLTableMasterPageExport.cxx | 16 +++----
sc/source/filter/xml/XMLTableShapeImportHelper.cxx | 2
sc/source/filter/xml/xmlexprt.cxx | 36 ++++++++---------
sc/source/filter/xml/xmlimprt.cxx | 6 +-
sc/source/filter/xml/xmlrowi.cxx | 4 -
sc/source/filter/xml/xmlwrap.cxx | 5 --
sc/source/ui/Accessibility/AccessibleCellBase.cxx | 14 +++---
sc/source/ui/attrdlg/scabstdlg.cxx | 2
sc/source/ui/docshell/dbdocimp.cxx | 11 +----
sc/source/ui/docshell/docsh.cxx | 18 ++++----
sc/source/ui/docshell/docsh4.cxx | 2
sc/source/ui/docshell/docsh8.cxx | 24 +++++------
sc/source/ui/docshell/impex.cxx | 2
sc/source/ui/formdlg/formula.cxx | 2
sc/source/ui/miscdlgs/solverutil.cxx | 4 -
sc/source/ui/unoobj/dapiuno.cxx | 12 ++---
sc/source/ui/vba/vbaapplication.cxx | 2
sc/source/ui/vba/vbaaxis.cxx | 2
sc/source/ui/vba/vbaformat.cxx | 30 +++++++-------
sc/source/ui/vba/vbawindow.cxx | 2
sc/source/ui/vba/vbaworksheet.cxx | 4 -
sc/source/ui/view/cellsh2.cxx | 2
sc/source/ui/view/dbfunc3.cxx | 2
sc/source/ui/view/viewfun5.cxx | 2
32 files changed, 136 insertions(+), 148 deletions(-)
New commits:
commit be91a4725d851c05ea8a9ca2eb9ef01954aa06ec
Author: Noel Grandin <noel at peralex.com>
Date: Wed Nov 4 08:37:36 2015 +0200
loplugin:stringconstant
Change-Id: I9d3b60bb9f0d8c09968e2be1035fb8e654ac9c95
Reviewed-on: https://gerrit.libreoffice.org/19769
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin at gmail.com>
diff --git a/sc/source/core/data/dpobject.cxx b/sc/source/core/data/dpobject.cxx
index e956971..50fc32d 100644
--- a/sc/source/core/data/dpobject.cxx
+++ b/sc/source/core/data/dpobject.cxx
@@ -1276,8 +1276,7 @@ bool ScDPObject::IsDuplicated( long nDim )
{
try
{
- uno::Any aOrigAny = xDimProp->getPropertyValue(
- OUString(SC_UNO_DP_ORIGINAL) );
+ uno::Any aOrigAny = xDimProp->getPropertyValue( SC_UNO_DP_ORIGINAL );
uno::Reference<uno::XInterface> xIntOrig;
if ( (aOrigAny >>= xIntOrig) && xIntOrig.is() )
bDuplicated = true;
@@ -2018,8 +2017,7 @@ static sal_uInt16 lcl_FirstSubTotal( const uno::Reference<beans::XPropertySet>&
uno::Any aSubAny;
try
{
- aSubAny = xLevProp->getPropertyValue(
- OUString(SC_UNO_DP_SUBTOTAL) );
+ aSubAny = xLevProp->getPropertyValue( SC_UNO_DP_SUBTOTAL );
}
catch(uno::Exception&)
{
@@ -2117,8 +2115,7 @@ void lcl_FillOldFields( ScPivotFieldVector& rFields,
long nDupSource = -1;
try
{
- uno::Any aOrigAny = xDimProp->getPropertyValue(
- OUString(SC_UNO_DP_ORIGINAL_POS));
+ uno::Any aOrigAny = xDimProp->getPropertyValue(SC_UNO_DP_ORIGINAL_POS);
sal_Int32 nTmp = 0;
if (aOrigAny >>= nTmp)
nDupSource = static_cast<sal_Int32>(nTmp);
@@ -2165,7 +2162,7 @@ void lcl_FillOldFields( ScPivotFieldVector& rFields,
try
{
if (nOrient == sheet::DataPilotFieldOrientation_DATA)
- xDimProp->getPropertyValue(OUString(SC_UNO_DP_REFVALUE))
+ xDimProp->getPropertyValue(SC_UNO_DP_REFVALUE)
>>= rField.maFieldRef;
}
catch (uno::Exception&)
@@ -2281,11 +2278,11 @@ static void lcl_FillLabelData( ScDPLabelData& rData, const uno::Reference< beans
try
{
- xLevProp->getPropertyValue( OUString( SC_UNO_DP_SORTING ) )
+ xLevProp->getPropertyValue( SC_UNO_DP_SORTING )
>>= rData.maSortInfo;
- xLevProp->getPropertyValue( OUString( SC_UNO_DP_LAYOUT ) )
+ xLevProp->getPropertyValue( SC_UNO_DP_LAYOUT )
>>= rData.maLayoutInfo;
- xLevProp->getPropertyValue( OUString( SC_UNO_DP_AUTOSHOW ) )
+ xLevProp->getPropertyValue( SC_UNO_DP_AUTOSHOW )
>>= rData.maShowInfo;
}
catch(uno::Exception&)
@@ -2313,8 +2310,7 @@ bool ScDPObject::FillLabelDataForDimension(
try
{
aFieldName = xDimName->getName();
- uno::Any aOrigAny = xDimProp->getPropertyValue(
- OUString(SC_UNO_DP_ORIGINAL_POS));
+ uno::Any aOrigAny = xDimProp->getPropertyValue(SC_UNO_DP_ORIGINAL_POS);
aOrigAny >>= nOrigPos;
}
catch(uno::Exception&)
@@ -2672,7 +2668,7 @@ bool ScDPObject::HasRegisteredSources()
if ( xEnAc.is() )
{
uno::Reference<container::XEnumeration> xEnum = xEnAc->createContentEnumeration(
- OUString( SCDPSOURCE_SERVICE ) );
+ SCDPSOURCE_SERVICE );
if ( xEnum.is() && xEnum->hasMoreElements() )
bFound = true;
}
@@ -2691,7 +2687,7 @@ uno::Sequence<OUString> ScDPObject::GetRegisteredSources()
if ( xEnAc.is() )
{
uno::Reference<container::XEnumeration> xEnum = xEnAc->createContentEnumeration(
- OUString( SCDPSOURCE_SERVICE ) );
+ SCDPSOURCE_SERVICE );
if ( xEnum.is() )
{
long nCount = 0;
@@ -2733,7 +2729,7 @@ uno::Reference<sheet::XDimensionsSupplier> ScDPObject::CreateSource( const ScDPS
return xRet;
uno::Reference<container::XEnumeration> xEnum =
- xEnAc->createContentEnumeration(OUString(SCDPSOURCE_SERVICE));
+ xEnAc->createContentEnumeration(SCDPSOURCE_SERVICE);
if (!xEnum.is())
return xRet;
@@ -3178,16 +3174,13 @@ uno::Reference<sdbc::XRowSet> ScDPCollection::DBCaches::createRowSet(
uno::Any aAny;
aAny <<= rDBName;
- xRowProp->setPropertyValue(
- OUString(SC_DBPROP_DATASOURCENAME), aAny );
+ xRowProp->setPropertyValue( SC_DBPROP_DATASOURCENAME, aAny );
aAny <<= rCommand;
- xRowProp->setPropertyValue(
- OUString(SC_DBPROP_COMMAND), aAny );
+ xRowProp->setPropertyValue( SC_DBPROP_COMMAND, aAny );
aAny <<= nSdbType;
- xRowProp->setPropertyValue(
- OUString(SC_DBPROP_COMMANDTYPE), aAny );
+ xRowProp->setPropertyValue( SC_DBPROP_COMMANDTYPE, aAny );
uno::Reference<sdb::XCompletedExecution> xExecute( xRowSet, uno::UNO_QUERY );
if ( xExecute.is() )
diff --git a/sc/source/core/data/dpoutput.cxx b/sc/source/core/data/dpoutput.cxx
index a277ab5..cea5a7d 100644
--- a/sc/source/core/data/dpoutput.cxx
+++ b/sc/source/core/data/dpoutput.cxx
@@ -704,8 +704,7 @@ ScDPOutput::ScDPOutput( ScDocument* pD, const uno::Reference<sheet::XDimensionsS
{
try
{
- uno::Any aAny = xSrcProp->getPropertyValue(
- OUString(SC_UNO_DP_DATADESC) );
+ uno::Any aAny = xSrcProp->getPropertyValue( SC_UNO_DP_DATADESC );
OUString aUStr;
aAny >>= aUStr;
aDataDescription = aUStr;
diff --git a/sc/source/core/data/dpsave.cxx b/sc/source/core/data/dpsave.cxx
index ab3a1cc..2187508 100644
--- a/sc/source/core/data/dpsave.cxx
+++ b/sc/source/core/data/dpsave.cxx
@@ -565,22 +565,22 @@ void ScDPSaveDimension::WriteToSource( const uno::Reference<uno::XInterface>& xD
sheet::DataPilotFieldOrientation eOrient = (sheet::DataPilotFieldOrientation)nOrientation;
aAny <<= eOrient;
- xDimProp->setPropertyValue( OUString(SC_UNO_DP_ORIENTATION), aAny );
+ xDimProp->setPropertyValue( SC_UNO_DP_ORIENTATION, aAny );
sheet::GeneralFunction eFunc = (sheet::GeneralFunction)nFunction;
aAny <<= eFunc;
- xDimProp->setPropertyValue( OUString(SC_UNO_DP_FUNCTION), aAny );
+ xDimProp->setPropertyValue( SC_UNO_DP_FUNCTION, aAny );
if ( nUsedHierarchy >= 0 )
{
aAny <<= (sal_Int32)nUsedHierarchy;
- xDimProp->setPropertyValue( OUString(SC_UNO_DP_USEDHIERARCHY), aAny );
+ xDimProp->setPropertyValue( SC_UNO_DP_USEDHIERARCHY, aAny );
}
if ( pReferenceValue )
{
aAny <<= *pReferenceValue;
- xDimProp->setPropertyValue( OUString(SC_UNO_DP_REFVALUE), aAny );
+ xDimProp->setPropertyValue( SC_UNO_DP_REFVALUE, aAny );
}
if (mpLayoutName)
@@ -641,7 +641,7 @@ void ScDPSaveDimension::WriteToSource( const uno::Reference<uno::XInterface>& xD
for (long i=0; i<nSubTotalCount; i++)
pArray[i] = (sheet::GeneralFunction)pSubTotalFuncs[i];
aAny <<= aSeq;
- xLevProp->setPropertyValue( OUString(SC_UNO_DP_SUBTOTAL), aAny );
+ xLevProp->setPropertyValue( SC_UNO_DP_SUBTOTAL, aAny );
}
if ( nShowEmptyMode != SC_DPSAVEMODE_DONTKNOW )
lcl_SetBoolProperty( xLevProp,
@@ -1158,7 +1158,7 @@ static void lcl_ResetOrient( const uno::Reference<sheet::XDimensionsSupplier>& x
{
uno::Any aAny;
aAny <<= eOrient;
- xDimProp->setPropertyValue( OUString(SC_UNO_DP_ORIENTATION), aAny );
+ xDimProp->setPropertyValue( SC_UNO_DP_ORIENTATION, aAny );
}
}
}
diff --git a/sc/source/core/tool/formulaparserpool.cxx b/sc/source/core/tool/formulaparserpool.cxx
index c310279..8fa6114 100644
--- a/sc/source/core/tool/formulaparserpool.cxx
+++ b/sc/source/core/tool/formulaparserpool.cxx
@@ -61,7 +61,7 @@ ScParserFactoryMap::ScParserFactoryMap() :
{
// enumerate all implementations of the FormulaParser service
Reference< XContentEnumerationAccess > xFactoryEA( mxContext->getServiceManager(), UNO_QUERY_THROW );
- Reference< XEnumeration > xEnum( xFactoryEA->createContentEnumeration( OUString( "com.sun.star.sheet.FilterFormulaParser" ) ), UNO_SET_THROW );
+ Reference< XEnumeration > xEnum( xFactoryEA->createContentEnumeration( "com.sun.star.sheet.FilterFormulaParser" ), UNO_SET_THROW );
while( xEnum->hasMoreElements() ) try // single try/catch for every element
{
// create an instance of the formula parser implementation
diff --git a/sc/source/filter/excel/xltoolbar.cxx b/sc/source/filter/excel/xltoolbar.cxx
index b4aa420..df10559 100644
--- a/sc/source/filter/excel/xltoolbar.cxx
+++ b/sc/source/filter/excel/xltoolbar.cxx
@@ -418,7 +418,7 @@ bool ScCTBWrapper::ImportCustomToolBar( SfxObjectShell& rDocSh )
for ( std::vector<ScCTB>::iterator it = rCTB.begin(); it != it_end; ++it )
{
// for each customtoolbar
- CustomToolBarImportHelper helper( rDocSh, xAppCfgSupp->getUIConfigurationManager( OUString("com.sun.star.sheet.SpreadsheetDocument" ) ) );
+ CustomToolBarImportHelper helper( rDocSh, xAppCfgSupp->getUIConfigurationManager( "com.sun.star.sheet.SpreadsheetDocument" ) );
helper.setMSOCommandMap( new MSOExcelCommandConvertor() );
// Ignore menu toolbars, excel doesn't ( afaics ) store
// menu customizations ( but you can have menus in a customtoolbar
diff --git a/sc/source/filter/xml/XMLCalculationSettingsContext.cxx b/sc/source/filter/xml/XMLCalculationSettingsContext.cxx
index f2dfa3f..7fb7b29 100644
--- a/sc/source/filter/xml/XMLCalculationSettingsContext.cxx
+++ b/sc/source/filter/xml/XMLCalculationSettingsContext.cxx
@@ -127,15 +127,15 @@ void ScXMLCalculationSettingsContext::EndElement()
uno::Reference <beans::XPropertySet> xPropertySet (GetScImport().GetModel(), uno::UNO_QUERY);
if (xPropertySet.is())
{
- xPropertySet->setPropertyValue(OUString(SC_UNO_CALCASSHOWN), uno::makeAny(bCalcAsShown) );
- xPropertySet->setPropertyValue(OUString(SC_UNO_IGNORECASE), uno::makeAny(bIgnoreCase) );
- xPropertySet->setPropertyValue(OUString(SC_UNO_LOOKUPLABELS), uno::makeAny(bLookUpLabels) );
- xPropertySet->setPropertyValue(OUString(SC_UNO_MATCHWHOLE), uno::makeAny(bMatchWholeCell) );
- xPropertySet->setPropertyValue(OUString(SC_UNO_REGEXENABLED), uno::makeAny(bUseRegularExpressions) );
- xPropertySet->setPropertyValue(OUString(SC_UNO_ITERENABLED), uno::makeAny(bIsIterationEnabled) );
- xPropertySet->setPropertyValue( OUString(SC_UNO_ITERCOUNT), uno::makeAny(nIterationCount) );
- xPropertySet->setPropertyValue( OUString(SC_UNO_ITEREPSILON), uno::makeAny(fIterationEpsilon) );
- xPropertySet->setPropertyValue( OUString(SC_UNO_NULLDATE), uno::makeAny(aNullDate) );
+ xPropertySet->setPropertyValue( SC_UNO_CALCASSHOWN, uno::makeAny(bCalcAsShown) );
+ xPropertySet->setPropertyValue( SC_UNO_IGNORECASE, uno::makeAny(bIgnoreCase) );
+ xPropertySet->setPropertyValue( SC_UNO_LOOKUPLABELS, uno::makeAny(bLookUpLabels) );
+ xPropertySet->setPropertyValue( SC_UNO_MATCHWHOLE, uno::makeAny(bMatchWholeCell) );
+ xPropertySet->setPropertyValue( SC_UNO_REGEXENABLED, uno::makeAny(bUseRegularExpressions) );
+ xPropertySet->setPropertyValue( SC_UNO_ITERENABLED, uno::makeAny(bIsIterationEnabled) );
+ xPropertySet->setPropertyValue( SC_UNO_ITERCOUNT, uno::makeAny(nIterationCount) );
+ xPropertySet->setPropertyValue( SC_UNO_ITEREPSILON, uno::makeAny(fIterationEpsilon) );
+ xPropertySet->setPropertyValue( SC_UNO_NULLDATE, uno::makeAny(aNullDate) );
if (GetScImport().GetDocument())
{
ScXMLImport::MutexGuard aGuard(GetScImport());
diff --git a/sc/source/filter/xml/XMLExportDDELinks.cxx b/sc/source/filter/xml/XMLExportDDELinks.cxx
index afe8d47..ece97a3 100644
--- a/sc/source/filter/xml/XMLExportDDELinks.cxx
+++ b/sc/source/filter/xml/XMLExportDDELinks.cxx
@@ -122,7 +122,7 @@ void ScXMLExportDDELinks::WriteDDELinks(uno::Reference<sheet::XSpreadsheetDocume
uno::Reference <beans::XPropertySet> xPropertySet (xSpreadDoc, uno::UNO_QUERY);
if (xPropertySet.is())
{
- uno::Reference<container::XIndexAccess> xIndex(xPropertySet->getPropertyValue(OUString(SC_UNO_DDELINKS)), uno::UNO_QUERY);
+ uno::Reference<container::XIndexAccess> xIndex(xPropertySet->getPropertyValue(SC_UNO_DDELINKS), uno::UNO_QUERY);
if (xIndex.is())
{
sal_Int32 nCount = xIndex->getCount();
diff --git a/sc/source/filter/xml/XMLExportDatabaseRanges.cxx b/sc/source/filter/xml/XMLExportDatabaseRanges.cxx
index a543657..88f5698 100644
--- a/sc/source/filter/xml/XMLExportDatabaseRanges.cxx
+++ b/sc/source/filter/xml/XMLExportDatabaseRanges.cxx
@@ -74,7 +74,7 @@ ScMyEmptyDatabaseRangesContainer ScXMLExportDatabaseRanges::GetEmptyDatabaseRang
uno::Reference <beans::XPropertySet> xPropertySet (rExport.GetModel(), uno::UNO_QUERY);
if (xPropertySet.is())
{
- uno::Reference <sheet::XDatabaseRanges> xDatabaseRanges(xPropertySet->getPropertyValue(OUString(SC_UNO_DATABASERNG)), uno::UNO_QUERY);
+ uno::Reference <sheet::XDatabaseRanges> xDatabaseRanges(xPropertySet->getPropertyValue(SC_UNO_DATABASERNG), uno::UNO_QUERY);
rExport.CheckAttrList();
if (xDatabaseRanges.is())
{
@@ -88,7 +88,7 @@ ScMyEmptyDatabaseRangesContainer ScXMLExportDatabaseRanges::GetEmptyDatabaseRang
{
uno::Reference <beans::XPropertySet> xDatabaseRangePropertySet (xDatabaseRange, uno::UNO_QUERY);
if (xDatabaseRangePropertySet.is() &&
- ::cppu::any2bool(xDatabaseRangePropertySet->getPropertyValue(OUString(SC_UNONAME_STRIPDAT))))
+ ::cppu::any2bool(xDatabaseRangePropertySet->getPropertyValue(SC_UNONAME_STRIPDAT)))
{
uno::Sequence <beans::PropertyValue> aImportProperties(xDatabaseRange->getImportDescriptor());
sal_Int32 nLength = aImportProperties.getLength();
diff --git a/sc/source/filter/xml/XMLTableMasterPageExport.cxx b/sc/source/filter/xml/XMLTableMasterPageExport.cxx
index 3bf6008..260deea 100644
--- a/sc/source/filter/xml/XMLTableMasterPageExport.cxx
+++ b/sc/source/filter/xml/XMLTableMasterPageExport.cxx
@@ -109,13 +109,13 @@ void XMLTableMasterPageExport::exportMasterPageContent(
const Reference < XPropertySet > & rPropSet,
bool bAutoStyles )
{
- Reference < sheet::XHeaderFooterContent > xHeader(rPropSet->getPropertyValue( OUString( SC_UNO_PAGE_RIGHTHDRCON ) ), uno::UNO_QUERY);
+ Reference < sheet::XHeaderFooterContent > xHeader(rPropSet->getPropertyValue( SC_UNO_PAGE_RIGHTHDRCON ), uno::UNO_QUERY);
- Reference < sheet::XHeaderFooterContent > xHeaderLeft(rPropSet->getPropertyValue( OUString( SC_UNO_PAGE_LEFTHDRCONT ) ), uno::UNO_QUERY);
+ Reference < sheet::XHeaderFooterContent > xHeaderLeft(rPropSet->getPropertyValue( SC_UNO_PAGE_LEFTHDRCONT ), uno::UNO_QUERY);
- Reference < sheet::XHeaderFooterContent > xFooter(rPropSet->getPropertyValue( OUString( SC_UNO_PAGE_RIGHTFTRCON ) ), uno::UNO_QUERY);
+ Reference < sheet::XHeaderFooterContent > xFooter(rPropSet->getPropertyValue( SC_UNO_PAGE_RIGHTFTRCON ), uno::UNO_QUERY);
- Reference < sheet::XHeaderFooterContent > xFooterLeft(rPropSet->getPropertyValue( OUString( SC_UNO_PAGE_LEFTFTRCONT ) ), uno::UNO_QUERY);
+ Reference < sheet::XHeaderFooterContent > xFooterLeft(rPropSet->getPropertyValue( SC_UNO_PAGE_LEFTFTRCONT ), uno::UNO_QUERY);
if( bAutoStyles )
{
@@ -146,19 +146,19 @@ void XMLTableMasterPageExport::exportMasterPageContent(
}
else
{
- bool bHeader(::cppu::any2bool(rPropSet->getPropertyValue( OUString( SC_UNO_PAGE_HDRON ) )));
+ bool bHeader(::cppu::any2bool(rPropSet->getPropertyValue( SC_UNO_PAGE_HDRON )));
exportHeaderFooter(xHeader, XML_HEADER, bHeader );
- bool bLeftHeader(!::cppu::any2bool(rPropSet->getPropertyValue( OUString( SC_UNO_PAGE_HDRSHARED ) )) && bHeader);
+ bool bLeftHeader(!::cppu::any2bool(rPropSet->getPropertyValue( SC_UNO_PAGE_HDRSHARED )) && bHeader);
exportHeaderFooter( xHeaderLeft, XML_HEADER_LEFT, bLeftHeader );
- bool bFooter(::cppu::any2bool(rPropSet->getPropertyValue( OUString( SC_UNO_PAGE_FTRON ) )));
+ bool bFooter(::cppu::any2bool(rPropSet->getPropertyValue( SC_UNO_PAGE_FTRON )));
exportHeaderFooter( xFooter, XML_FOOTER, bFooter );
- bool bLeftFooter = (!::cppu::any2bool(rPropSet->getPropertyValue( OUString( SC_UNO_PAGE_FTRSHARED ) )) && bFooter);
+ bool bLeftFooter = (!::cppu::any2bool(rPropSet->getPropertyValue( SC_UNO_PAGE_FTRSHARED )) && bFooter);
exportHeaderFooter( xFooterLeft, XML_FOOTER_LEFT, bLeftFooter );
}
diff --git a/sc/source/filter/xml/XMLTableShapeImportHelper.cxx b/sc/source/filter/xml/XMLTableShapeImportHelper.cxx
index 6280175..fc96546 100644
--- a/sc/source/filter/xml/XMLTableShapeImportHelper.cxx
+++ b/sc/source/filter/xml/XMLTableShapeImportHelper.cxx
@@ -60,7 +60,7 @@ void XMLTableShapeImportHelper::SetLayer(uno::Reference<drawing::XShape>& rShape
{
uno::Reference< beans::XPropertySet > xShapeProp( rShape, uno::UNO_QUERY );
if( xShapeProp.is() )
- xShapeProp->setPropertyValue(OUString( SC_LAYERID ), uno::makeAny(nLayerID) );
+ xShapeProp->setPropertyValue( SC_LAYERID, uno::makeAny(nLayerID) );
}
}
diff --git a/sc/source/filter/xml/xmlexprt.cxx b/sc/source/filter/xml/xmlexprt.cxx
index 87d5c3d..9909bc7 100644
--- a/sc/source/filter/xml/xmlexprt.cxx
+++ b/sc/source/filter/xml/xmlexprt.cxx
@@ -324,7 +324,7 @@ void ScXMLShapeExport::onExport( const uno::Reference < drawing::XShape >& xShap
if( xShapeProp.is() )
{
sal_Int16 nLayerID = 0;
- if( (xShapeProp->getPropertyValue(OUString( SC_LAYERID )) >>= nLayerID) && (nLayerID == SC_LAYER_BACK) )
+ if( (xShapeProp->getPropertyValue( SC_LAYERID ) >>= nLayerID) && (nLayerID == SC_LAYER_BACK) )
GetExport().AddAttribute(XML_NAMESPACE_TABLE, XML_TABLE_BACKGROUND, XML_TRUE);
}
}
@@ -3385,7 +3385,7 @@ void ScXMLExport::ExportShape(const uno::Reference < drawing::XShape >& xShape,
{
uno::Reference< beans::XPropertySet > xProps( xShape, uno::UNO_QUERY );
if ( xProps.is() )
- xProps->getPropertyValue( OUString( SC_UNONAME_HYPERLINK ) ) >>= sHlink;
+ xProps->getPropertyValue( SC_UNONAME_HYPERLINK ) >>= sHlink;
}
catch ( const beans::UnknownPropertyException& )
{
@@ -3737,19 +3737,19 @@ void ScXMLExport::WriteCalculationSettings(const uno::Reference <sheet::XSpreads
uno::Reference<beans::XPropertySet> xPropertySet(xSpreadDoc, uno::UNO_QUERY);
if (xPropertySet.is())
{
- bool bCalcAsShown (::cppu::any2bool( xPropertySet->getPropertyValue(OUString(SC_UNO_CALCASSHOWN)) ));
- bool bIgnoreCase (::cppu::any2bool( xPropertySet->getPropertyValue(OUString(SC_UNO_IGNORECASE)) ));
- bool bLookUpLabels (::cppu::any2bool( xPropertySet->getPropertyValue(OUString(SC_UNO_LOOKUPLABELS)) ));
- bool bMatchWholeCell (::cppu::any2bool( xPropertySet->getPropertyValue(OUString(SC_UNO_MATCHWHOLE)) ));
- bool bUseRegularExpressions (::cppu::any2bool( xPropertySet->getPropertyValue(OUString(SC_UNO_REGEXENABLED)) ));
- bool bIsIterationEnabled (::cppu::any2bool( xPropertySet->getPropertyValue(OUString(SC_UNO_ITERENABLED)) ));
+ bool bCalcAsShown (::cppu::any2bool( xPropertySet->getPropertyValue(SC_UNO_CALCASSHOWN) ));
+ bool bIgnoreCase (::cppu::any2bool( xPropertySet->getPropertyValue(SC_UNO_IGNORECASE) ));
+ bool bLookUpLabels (::cppu::any2bool( xPropertySet->getPropertyValue(SC_UNO_LOOKUPLABELS) ));
+ bool bMatchWholeCell (::cppu::any2bool( xPropertySet->getPropertyValue(SC_UNO_MATCHWHOLE) ));
+ bool bUseRegularExpressions (::cppu::any2bool( xPropertySet->getPropertyValue(SC_UNO_REGEXENABLED) ));
+ bool bIsIterationEnabled (::cppu::any2bool( xPropertySet->getPropertyValue(SC_UNO_ITERENABLED) ));
sal_uInt16 nYear2000 (pDoc ? pDoc->GetDocOptions().GetYear2000() : 0);
sal_Int32 nIterationCount(100);
- xPropertySet->getPropertyValue( OUString(SC_UNO_ITERCOUNT)) >>= nIterationCount;
+ xPropertySet->getPropertyValue( SC_UNO_ITERCOUNT ) >>= nIterationCount;
double fIterationEpsilon = 0;
- xPropertySet->getPropertyValue( OUString(SC_UNO_ITEREPSILON)) >>= fIterationEpsilon;
+ xPropertySet->getPropertyValue( SC_UNO_ITEREPSILON ) >>= fIterationEpsilon;
util::Date aNullDate;
- xPropertySet->getPropertyValue( OUString(SC_UNO_NULLDATE)) >>= aNullDate;
+ xPropertySet->getPropertyValue( SC_UNO_NULLDATE ) >>= aNullDate;
if (bCalcAsShown || bIgnoreCase || !bLookUpLabels || !bMatchWholeCell || !bUseRegularExpressions ||
bIsIterationEnabled || nIterationCount != 100 || !::rtl::math::approxEqual(fIterationEpsilon, 0.001) ||
aNullDate.Day != 30 || aNullDate.Month != 12 || aNullDate.Year != 1899 || nYear2000 != 1930)
@@ -3815,7 +3815,7 @@ void ScXMLExport::WriteTableSource()
uno::Reference <beans::XPropertySet> xProps (GetModel(), uno::UNO_QUERY);
if (xProps.is())
{
- uno::Reference <container::XIndexAccess> xIndex(xProps->getPropertyValue(OUString(SC_UNO_SHEETLINKS)), uno::UNO_QUERY);
+ uno::Reference <container::XIndexAccess> xIndex(xProps->getPropertyValue(SC_UNO_SHEETLINKS), uno::UNO_QUERY);
if (xIndex.is())
{
sal_Int32 nCount(xIndex->getCount());
@@ -3829,7 +3829,7 @@ void ScXMLExport::WriteTableSource()
if (xLinkProps.is())
{
OUString sNewLink;
- if (xLinkProps->getPropertyValue(OUString(SC_UNONAME_LINKURL)) >>= sNewLink)
+ if (xLinkProps->getPropertyValue(SC_UNONAME_LINKURL) >>= sNewLink)
bFound = sLink.equals(sNewLink);
}
}
@@ -3839,9 +3839,9 @@ void ScXMLExport::WriteTableSource()
OUString sFilterOptions;
OUString sTableName (xLinkable->getLinkSheetName());
sal_Int32 nRefresh(0);
- xLinkProps->getPropertyValue(OUString(SC_UNONAME_FILTER)) >>= sFilter;
- xLinkProps->getPropertyValue(OUString(SC_UNONAME_FILTOPT)) >>= sFilterOptions;
- xLinkProps->getPropertyValue(OUString(SC_UNONAME_REFDELAY)) >>= nRefresh;
+ xLinkProps->getPropertyValue(SC_UNONAME_FILTER) >>= sFilter;
+ xLinkProps->getPropertyValue(SC_UNONAME_FILTOPT) >>= sFilterOptions;
+ xLinkProps->getPropertyValue(SC_UNONAME_REFDELAY) >>= nRefresh;
if (!sLink.isEmpty())
{
AddAttribute(XML_NAMESPACE_XLINK, XML_TYPE, XML_SIMPLE);
@@ -3912,11 +3912,11 @@ void ScXMLExport::WriteTheLabelRanges( const uno::Reference< sheet::XSpreadsheet
if( !xDocProp.is() ) return;
sal_Int32 nCount(0);
- uno::Reference< container::XIndexAccess > xColRangesIAccess(xDocProp->getPropertyValue( OUString( SC_UNO_COLLABELRNG ) ), uno::UNO_QUERY);
+ uno::Reference< container::XIndexAccess > xColRangesIAccess(xDocProp->getPropertyValue( SC_UNO_COLLABELRNG ), uno::UNO_QUERY);
if( xColRangesIAccess.is() )
nCount += xColRangesIAccess->getCount();
- uno::Reference< container::XIndexAccess > xRowRangesIAccess(xDocProp->getPropertyValue( OUString( SC_UNO_ROWLABELRNG ) ), uno::UNO_QUERY);
+ uno::Reference< container::XIndexAccess > xRowRangesIAccess(xDocProp->getPropertyValue( SC_UNO_ROWLABELRNG ), uno::UNO_QUERY);
if( xRowRangesIAccess.is() )
nCount += xRowRangesIAccess->getCount();
diff --git a/sc/source/filter/xml/xmlimprt.cxx b/sc/source/filter/xml/xmlimprt.cxx
index 579b6b8..85ba478 100644
--- a/sc/source/filter/xml/xmlimprt.cxx
+++ b/sc/source/filter/xml/xmlimprt.cxx
@@ -2702,7 +2702,7 @@ bool ScXMLImport::IsCurrencySymbol(const sal_Int32 nNumberFormat, const OUString
if (xNumberPropertySet.is())
{
OUString sTemp;
- if ( xNumberPropertySet->getPropertyValue(OUString(SC_CURRENCYSYMBOL)) >>= sTemp)
+ if ( xNumberPropertySet->getPropertyValue(SC_CURRENCYSYMBOL) >>= sTemp)
{
if (sCurrentCurrency.equals(sTemp))
return true;
@@ -3054,8 +3054,8 @@ void ScXMLImport::SetLabelRanges()
uno::Reference <beans::XPropertySet> xPropertySet (GetModel(), uno::UNO_QUERY);
if (xPropertySet.is())
{
- uno::Any aColAny = xPropertySet->getPropertyValue(OUString(SC_UNO_COLLABELRNG));
- uno::Any aRowAny = xPropertySet->getPropertyValue(OUString(SC_UNO_ROWLABELRNG));
+ uno::Any aColAny = xPropertySet->getPropertyValue(SC_UNO_COLLABELRNG);
+ uno::Any aRowAny = xPropertySet->getPropertyValue(SC_UNO_ROWLABELRNG);
uno::Reference< sheet::XLabelRanges > xColRanges;
uno::Reference< sheet::XLabelRanges > xRowRanges;
diff --git a/sc/source/filter/xml/xmlrowi.cxx b/sc/source/filter/xml/xmlrowi.cxx
index a3b30ba..ae29109 100644
--- a/sc/source/filter/xml/xmlrowi.cxx
+++ b/sc/source/filter/xml/xmlrowi.cxx
@@ -200,9 +200,9 @@ void ScXMLTableRowContext::EndElement()
bFiltered = true;
}
if (!bVisible)
- xRowProperties->setPropertyValue(OUString(SC_ISVISIBLE), uno::makeAny(bVisible));
+ xRowProperties->setPropertyValue(SC_ISVISIBLE, uno::makeAny(bVisible));
if (bFiltered)
- xRowProperties->setPropertyValue(OUString(SC_ISFILTERED), uno::makeAny(bFiltered));
+ xRowProperties->setPropertyValue(SC_ISFILTERED, uno::makeAny(bFiltered));
}
}
}
diff --git a/sc/source/filter/xml/xmlwrap.cxx b/sc/source/filter/xml/xmlwrap.cxx
index 7d9e871..f0cfb52 100644
--- a/sc/source/filter/xml/xmlwrap.cxx
+++ b/sc/source/filter/xml/xmlwrap.cxx
@@ -599,7 +599,7 @@ bool ScXMLImportWrapper::Import( sal_uInt8 nMode, ErrCode& rError )
if ( xModelSet.is() ) try
{
uno::Reference< script::vba::XVBACompatibility > xVBACompat( xModelSet->getPropertyValue(
- OUString( "BasicLibraries" ) ), uno::UNO_QUERY_THROW );
+ "BasicLibraries" ), uno::UNO_QUERY_THROW );
xVBACompat->setVBACompatibilityMode( sal_True );
}
catch( const uno::Exception& )
@@ -839,8 +839,7 @@ bool ScXMLImportWrapper::Export(bool bStylesOnly)
try
{
OUString aVersion;
- if (( xPropSet->getPropertyValue(
- OUString("Version")) >>= aVersion )
+ if (( xPropSet->getPropertyValue("Version") >>= aVersion )
&& aVersion != ODFVER_010_TEXT
&& aVersion != ODFVER_011_TEXT )
{
diff --git a/sc/source/ui/Accessibility/AccessibleCellBase.cxx b/sc/source/ui/Accessibility/AccessibleCellBase.cxx
index b8d6f63..65e9a54 100644
--- a/sc/source/ui/Accessibility/AccessibleCellBase.cxx
+++ b/sc/source/ui/Accessibility/AccessibleCellBase.cxx
@@ -118,7 +118,7 @@ sal_Int32 SAL_CALL ScAccessibleCellBase::getForeground()
uno::Reference<beans::XPropertySet> xCellProps(xCell, uno::UNO_QUERY);
if (xCellProps.is())
{
- uno::Any aAny = xCellProps->getPropertyValue(OUString(SC_UNONAME_CCOLOR));
+ uno::Any aAny = xCellProps->getPropertyValue(SC_UNONAME_CCOLOR);
aAny >>= nColor;
}
}
@@ -159,7 +159,7 @@ sal_Int32 SAL_CALL ScAccessibleCellBase::getBackground()
uno::Reference<beans::XPropertySet> xCellProps(xCell, uno::UNO_QUERY);
if (xCellProps.is())
{
- uno::Any aAny = xCellProps->getPropertyValue(OUString(SC_UNONAME_CELLBACK));
+ uno::Any aAny = xCellProps->getPropertyValue(SC_UNONAME_CELLBACK);
aAny >>= nColor;
}
}
@@ -392,7 +392,7 @@ OUString SAL_CALL ScAccessibleCellBase::getShadowAttrs()
uno::Reference<beans::XPropertySet> xCellProps(xCell, uno::UNO_QUERY);
if (xCellProps.is())
{
- uno::Any aAny = xCellProps->getPropertyValue(OUString(SC_UNONAME_SHADOW));
+ uno::Any aAny = xCellProps->getPropertyValue(SC_UNONAME_SHADOW);
aAny >>= aShadowFmt;
}
}
@@ -478,13 +478,13 @@ OUString SAL_CALL ScAccessibleCellBase::getBorderAttrs()
uno::Reference<beans::XPropertySet> xCellProps(xCell, uno::UNO_QUERY);
if (xCellProps.is())
{
- uno::Any aAny = xCellProps->getPropertyValue(OUString(SC_UNONAME_TOPBORDER));
+ uno::Any aAny = xCellProps->getPropertyValue(SC_UNONAME_TOPBORDER);
aAny >>= aTopBorder;
- aAny = xCellProps->getPropertyValue(OUString(SC_UNONAME_BOTTBORDER));
+ aAny = xCellProps->getPropertyValue(SC_UNONAME_BOTTBORDER);
aAny >>= aBottomBorder;
- aAny = xCellProps->getPropertyValue(OUString(SC_UNONAME_LEFTBORDER));
+ aAny = xCellProps->getPropertyValue(SC_UNONAME_LEFTBORDER);
aAny >>= aLeftBorder;
- aAny = xCellProps->getPropertyValue(OUString(SC_UNONAME_RIGHTBORDER));
+ aAny = xCellProps->getPropertyValue(SC_UNONAME_RIGHTBORDER);
aAny >>= aRightBorder;
}
}
diff --git a/sc/source/ui/attrdlg/scabstdlg.cxx b/sc/source/ui/attrdlg/scabstdlg.cxx
index fa4d966..cd8d1b7 100644
--- a/sc/source/ui/attrdlg/scabstdlg.cxx
+++ b/sc/source/ui/attrdlg/scabstdlg.cxx
@@ -49,7 +49,7 @@ ScAbstractDialogFactory* ScAbstractDialogFactory::Create()
if ( aDialogLibrary.is() || aDialogLibrary.loadRelative( &thisModule, aStrBuf.makeStringAndClear(),
SAL_LOADMODULE_GLOBAL | SAL_LOADMODULE_LAZY ) )
fp = reinterpret_cast<ScAbstractDialogFactory* (SAL_CALL*)()>(
- aDialogLibrary.getFunctionSymbol( OUString("ScCreateDialogFactory") ));
+ aDialogLibrary.getFunctionSymbol( "ScCreateDialogFactory" ));
#else
fp = ScCreateDialogFactory();
#endif
diff --git a/sc/source/ui/docshell/dbdocimp.cxx b/sc/source/ui/docshell/dbdocimp.cxx
index f2f9dce..08499ef 100644
--- a/sc/source/ui/docshell/dbdocimp.cxx
+++ b/sc/source/ui/docshell/dbdocimp.cxx
@@ -74,7 +74,7 @@ void ScDBDocFunc::ShowInBeamer( const ScImportParam& rParam, SfxViewFrame* pFram
uno::Reference<frame::XDispatchProvider> xDP(xFrame, uno::UNO_QUERY);
uno::Reference<frame::XFrame> xBeamerFrame = xFrame->findFrame(
- OUString("_beamer"),
+ "_beamer",
frame::FrameSearchFlag::CHILDREN);
if (xBeamerFrame.is())
{
@@ -217,16 +217,13 @@ bool ScDBDocFunc::DoImport( SCTAB nTab, const ScImportParam& rParam,
uno::Any aAny;
aAny <<= rParam.aDBName;
- xRowProp->setPropertyValue(
- OUString(SC_DBPROP_DATASOURCENAME), aAny );
+ xRowProp->setPropertyValue( SC_DBPROP_DATASOURCENAME, aAny );
aAny <<= rParam.aStatement;
- xRowProp->setPropertyValue(
- OUString(SC_DBPROP_COMMAND), aAny );
+ xRowProp->setPropertyValue( SC_DBPROP_COMMAND, aAny );
aAny <<= nType;
- xRowProp->setPropertyValue(
- OUString(SC_DBPROP_COMMANDTYPE), aAny );
+ xRowProp->setPropertyValue( SC_DBPROP_COMMANDTYPE, aAny );
uno::Reference<sdb::XCompletedExecution> xExecute( xRowSet, uno::UNO_QUERY );
if ( xExecute.is() )
diff --git a/sc/source/ui/docshell/docsh.cxx b/sc/source/ui/docshell/docsh.cxx
index f1eadfd..9124f07 100644
--- a/sc/source/ui/docshell/docsh.cxx
+++ b/sc/source/ui/docshell/docsh.cxx
@@ -713,7 +713,7 @@ void ScDocShell::Notify( SfxBroadcaster&, const SfxHint& rHint )
uno::UNO_QUERY_THROW );
uno::Reference< container::XContentEnumerationAccess > xEnumAccess( xServiceManager, uno::UNO_QUERY_THROW );
uno::Reference< container::XEnumeration> xEnum = xEnumAccess->createContentEnumeration(
- OUString( "com.sun.star.sheet.SpreadsheetDocumentJob" ) );
+ "com.sun.star.sheet.SpreadsheetDocumentJob" );
if ( xEnum.is() )
{
while ( xEnum->hasMoreElements() )
@@ -2969,7 +2969,7 @@ void ScDocShell::ResetKeyBindings( ScOptionsUtil::KeyBindingType eType )
// Grab the Calc configuration.
Reference<XUIConfigurationManager> xConfigMgr =
xModuleCfgSupplier->getUIConfigurationManager(
- OUString("com.sun.star.sheet.SpreadsheetDocument"));
+ "com.sun.star.sheet.SpreadsheetDocument");
if (!xConfigMgr.is())
return;
@@ -3015,15 +3015,15 @@ void ScDocShell::ResetKeyBindings( ScOptionsUtil::KeyBindingType eType )
switch (eType)
{
case ScOptionsUtil::KEY_DEFAULT:
- xScAccel->setKeyEvent(aDelete, OUString(".uno:ClearContents"));
- xScAccel->setKeyEvent(aBackspace, OUString(".uno:Delete"));
- xScAccel->setKeyEvent(aCtrlD, OUString(".uno:FillDown"));
- xScAccel->setKeyEvent(aAltDown, OUString(".uno:DataSelect"));
+ xScAccel->setKeyEvent(aDelete, ".uno:ClearContents");
+ xScAccel->setKeyEvent(aBackspace, ".uno:Delete");
+ xScAccel->setKeyEvent(aCtrlD, ".uno:FillDown");
+ xScAccel->setKeyEvent(aAltDown, ".uno:DataSelect");
break;
case ScOptionsUtil::KEY_OOO_LEGACY:
- xScAccel->setKeyEvent(aDelete, OUString(".uno:Delete"));
- xScAccel->setKeyEvent(aBackspace, OUString(".uno:ClearContents"));
- xScAccel->setKeyEvent(aCtrlD, OUString(".uno:DataSelect"));
+ xScAccel->setKeyEvent(aDelete, ".uno:Delete");
+ xScAccel->setKeyEvent(aBackspace, ".uno:ClearContents");
+ xScAccel->setKeyEvent(aCtrlD, ".uno:DataSelect");
break;
default:
;
diff --git a/sc/source/ui/docshell/docsh4.cxx b/sc/source/ui/docshell/docsh4.cxx
index 91e064a..e3fc6a3 100644
--- a/sc/source/ui/docshell/docsh4.cxx
+++ b/sc/source/ui/docshell/docsh4.cxx
@@ -2375,7 +2375,7 @@ uno::Reference< frame::XModel > ScDocShell::LoadSharedDocument()
}
xModel.set(
- xLoader->loadComponentFromURL( GetSharedFileURL(), OUString( "_blank" ), 0, aArgs ),
+ xLoader->loadComponentFromURL( GetSharedFileURL(), "_blank", 0, aArgs ),
uno::UNO_QUERY_THROW );
SC_MOD()->SetInSharedDocLoading( false );
}
diff --git a/sc/source/ui/docshell/docsh8.cxx b/sc/source/ui/docshell/docsh8.cxx
index 411dbef..c708bdc 100644
--- a/sc/source/ui/docshell/docsh8.cxx
+++ b/sc/source/ui/docshell/docsh8.cxx
@@ -329,16 +329,16 @@ sal_uLong ScDocShell::DBaseImport( const OUString& rFullFileName, rtl_TextEncodi
uno::Any aAny;
aAny <<= xConnection;
- xRowProp->setPropertyValue( OUString(SC_DBPROP_ACTIVECONNECTION), aAny );
+ xRowProp->setPropertyValue( SC_DBPROP_ACTIVECONNECTION, aAny );
aAny <<= nType;
- xRowProp->setPropertyValue( OUString(SC_DBPROP_COMMANDTYPE), aAny );
+ xRowProp->setPropertyValue( SC_DBPROP_COMMANDTYPE, aAny );
aAny <<= OUString( aTabName );
- xRowProp->setPropertyValue( OUString(SC_DBPROP_COMMAND), aAny );
+ xRowProp->setPropertyValue( SC_DBPROP_COMMAND, aAny );
aAny <<= false;
- xRowProp->setPropertyValue( OUString(SC_DBPROP_PROPCHANGE_NOTIFY), aAny );
+ xRowProp->setPropertyValue( SC_DBPROP_PROPCHANGE_NOTIFY, aAny );
xRowSet->execute();
@@ -871,7 +871,7 @@ sal_uLong ScDocShell::DBaseExport( const OUString& rFullFileName, rtl_TextEncodi
if (!xTableDesc.is()) return SCERR_EXPORT_CONNECT;
aAny <<= OUString( aTabName );
- xTableDesc->setPropertyValue( OUString(SC_DBPROP_NAME), aAny );
+ xTableDesc->setPropertyValue( SC_DBPROP_NAME, aAny );
// create columns
@@ -904,16 +904,16 @@ sal_uLong ScDocShell::DBaseExport( const OUString& rFullFileName, rtl_TextEncodi
if (!xColumnDesc.is()) return SCERR_EXPORT_CONNECT;
aAny <<= pColNames[nCol];
- xColumnDesc->setPropertyValue( OUString(SC_DBPROP_NAME), aAny );
+ xColumnDesc->setPropertyValue( SC_DBPROP_NAME, aAny );
aAny <<= pColTypes[nCol];
- xColumnDesc->setPropertyValue( OUString(SC_DBPROP_TYPE), aAny );
+ xColumnDesc->setPropertyValue( SC_DBPROP_TYPE, aAny );
aAny <<= pColLengths[nCol];
- xColumnDesc->setPropertyValue( OUString(SC_DBPROP_PRECISION), aAny );
+ xColumnDesc->setPropertyValue( SC_DBPROP_PRECISION, aAny );
aAny <<= pColScales[nCol];
- xColumnDesc->setPropertyValue( OUString(SC_DBPROP_SCALE), aAny );
+ xColumnDesc->setPropertyValue( SC_DBPROP_SCALE, aAny );
xColumnsAppend->appendByDescriptor( xColumnDesc );
}
@@ -930,13 +930,13 @@ sal_uLong ScDocShell::DBaseExport( const OUString& rFullFileName, rtl_TextEncodi
if (!xRowProp.is()) return SCERR_EXPORT_CONNECT;
aAny <<= xConnection;
- xRowProp->setPropertyValue( OUString(SC_DBPROP_ACTIVECONNECTION), aAny );
+ xRowProp->setPropertyValue( SC_DBPROP_ACTIVECONNECTION, aAny );
aAny <<= (sal_Int32) sdb::CommandType::TABLE;
- xRowProp->setPropertyValue( OUString(SC_DBPROP_COMMANDTYPE), aAny );
+ xRowProp->setPropertyValue( SC_DBPROP_COMMANDTYPE, aAny );
aAny <<= OUString( aTabName );
- xRowProp->setPropertyValue( OUString(SC_DBPROP_COMMAND), aAny );
+ xRowProp->setPropertyValue( SC_DBPROP_COMMAND, aAny );
xRowSet->execute();
diff --git a/sc/source/ui/docshell/impex.cxx b/sc/source/ui/docshell/impex.cxx
index 6f2164f..bf3fe8f 100644
--- a/sc/source/ui/docshell/impex.cxx
+++ b/sc/source/ui/docshell/impex.cxx
@@ -2257,7 +2257,7 @@ ScFormatFilterPlugin &ScFormatFilter::Get()
bLoaded = aModule.load(sFilterLib);
if (bLoaded)
{
- oslGenericFunction fn = aModule.getFunctionSymbol( OUString( "ScFilterCreate" ) );
+ oslGenericFunction fn = aModule.getFunctionSymbol( "ScFilterCreate" );
if (fn != NULL)
plugin = reinterpret_cast<FilterFn>(fn)();
}
diff --git a/sc/source/ui/formdlg/formula.cxx b/sc/source/ui/formdlg/formula.cxx
index 4e51d2e..0a26cd4 100644
--- a/sc/source/ui/formdlg/formula.cxx
+++ b/sc/source/ui/formdlg/formula.cxx
@@ -95,7 +95,7 @@ ScFormulaDlg::ScFormulaDlg( SfxBindings* pB, SfxChildWindow* pCW,
pDoc = pViewData->GetDocument();
m_xParser.set(ScServiceProvider::MakeInstance(SC_SERVICE_FORMULAPARS, static_cast<ScDocShell*>(pDoc->GetDocumentShell())),uno::UNO_QUERY);
uno::Reference< beans::XPropertySet> xSet(m_xParser,uno::UNO_QUERY);
- xSet->setPropertyValue(OUString(SC_UNO_COMPILEFAP),uno::makeAny(sal_True));
+ xSet->setPropertyValue(SC_UNO_COMPILEFAP, uno::makeAny(sal_True));
m_xOpCodeMapper.set(ScServiceProvider::MakeInstance(SC_SERVICE_OPCODEMAPPER, static_cast<ScDocShell*>(pDoc->GetDocumentShell())),uno::UNO_QUERY);
diff --git a/sc/source/ui/miscdlgs/solverutil.cxx b/sc/source/ui/miscdlgs/solverutil.cxx
index d62e63e..e047cb9 100644
--- a/sc/source/ui/miscdlgs/solverutil.cxx
+++ b/sc/source/ui/miscdlgs/solverutil.cxx
@@ -48,7 +48,7 @@ void ScSolverUtil::GetImplementations( uno::Sequence<OUString>& rImplNames,
if ( xEnAc.is() )
{
uno::Reference<container::XEnumeration> xEnum =
- xEnAc->createContentEnumeration( OUString(SCSOLVER_SERVICE) );
+ xEnAc->createContentEnumeration( SCSOLVER_SERVICE );
if ( xEnum.is() )
{
sal_Int32 nCount = 0;
@@ -98,7 +98,7 @@ uno::Reference<sheet::XSolver> ScSolverUtil::GetSolver( const OUString& rImplNam
if ( xEnAc.is() )
{
uno::Reference<container::XEnumeration> xEnum =
- xEnAc->createContentEnumeration( OUString(SCSOLVER_SERVICE) );
+ xEnAc->createContentEnumeration( SCSOLVER_SERVICE );
if ( xEnum.is() )
{
while ( xEnum->hasMoreElements() && !xSolver.is() )
diff --git a/sc/source/ui/unoobj/dapiuno.cxx b/sc/source/ui/unoobj/dapiuno.cxx
index bad5abf..d054d82 100644
--- a/sc/source/ui/unoobj/dapiuno.cxx
+++ b/sc/source/ui/unoobj/dapiuno.cxx
@@ -357,7 +357,7 @@ static bool lcl_IsDuplicated(const Reference<XPropertySet>& rDimProps)
{
try
{
- Any aAny = rDimProps->getPropertyValue( OUString( SC_UNO_DP_ORIGINAL ) );
+ Any aAny = rDimProps->getPropertyValue( SC_UNO_DP_ORIGINAL );
Reference< XNamed > xOriginal( aAny, UNO_QUERY );
return xOriginal.is();
}
@@ -376,7 +376,7 @@ static OUString lcl_GetOriginalName(const Reference< XNamed >& rDim)
{
try
{
- Any aAny = xDimProps->getPropertyValue(OUString(SC_UNO_DP_ORIGINAL));
+ Any aAny = xDimProps->getPropertyValue(SC_UNO_DP_ORIGINAL);
aAny >>= xOriginal;
}
catch( Exception& )
@@ -1562,7 +1562,7 @@ static sal_Int32 lcl_GetFieldCount( const Reference<XDimensionsSupplier>& rSourc
for (sal_Int32 i = 0; i < nIntCount; ++i)
{
xDim.set(xIntDims->getByIndex(i), UNO_QUERY);
- if (xDim.is() && (xDim->getPropertyValue(OUString(SC_UNO_DP_ORIENTATION)) == rOrient))
+ if (xDim.is() && (xDim->getPropertyValue(SC_UNO_DP_ORIENTATION) == rOrient))
++nRet;
}
}
@@ -1602,7 +1602,7 @@ static bool lcl_GetFieldDataByIndex( const Reference<XDimensionsSupplier>& rSour
while (i < nIntCount && !bOk)
{
xDim.set(xIntDims->getByIndex(i), UNO_QUERY);
- if (xDim.is() && (xDim->getPropertyValue(OUString(SC_UNO_DP_ORIENTATION)) == rOrient))
+ if (xDim.is() && (xDim->getPropertyValue(SC_UNO_DP_ORIENTATION) == rOrient))
{
if (nPos == nIndex)
{
@@ -3470,7 +3470,7 @@ Any SAL_CALL ScDataPilotItemObj::getPropertyValue( const OUString& aPropertyName
{
Reference< XPropertySet > xMemberProps( xMember, UNO_QUERY );
if( xMemberProps.is() )
- aRet = xMemberProps->getPropertyValue( OUString( SC_UNO_DP_SHOWDETAILS ) );
+ aRet = xMemberProps->getPropertyValue( SC_UNO_DP_SHOWDETAILS );
else
aRet <<= true;
}
@@ -3485,7 +3485,7 @@ Any SAL_CALL ScDataPilotItemObj::getPropertyValue( const OUString& aPropertyName
{
Reference< XPropertySet > xMemberProps( xMember, UNO_QUERY );
if( xMemberProps.is() )
- aRet <<= !cppu::any2bool( xMemberProps->getPropertyValue( OUString( SC_UNO_DP_ISVISIBLE ) ) );
+ aRet <<= !cppu::any2bool( xMemberProps->getPropertyValue( SC_UNO_DP_ISVISIBLE ) );
else
aRet <<= false;
}
diff --git a/sc/source/ui/vba/vbaapplication.cxx b/sc/source/ui/vba/vbaapplication.cxx
index 4f7d181..54cfc9d 100644
--- a/sc/source/ui/vba/vbaapplication.cxx
+++ b/sc/source/ui/vba/vbaapplication.cxx
@@ -485,7 +485,7 @@ ScVbaApplication::Names( const css::uno::Any& aIndex ) throw ( uno::RuntimeExcep
uno::Reference< frame::XModel > xModel( getCurrentDocument(), uno::UNO_QUERY_THROW );
uno::Reference< beans::XPropertySet > xPropertySet( xModel, uno::UNO_QUERY_THROW );
uno::Reference< sheet::XNamedRanges > xNamedRanges( xPropertySet->getPropertyValue(
- OUString( "NamedRanges" ) ), uno::UNO_QUERY_THROW );
+ "NamedRanges" ), uno::UNO_QUERY_THROW );
css::uno::Reference< excel::XNames > xNames ( new ScVbaNames( this , mxContext , xNamedRanges , xModel ) );
if ( aIndex.getValueTypeClass() == uno::TypeClass_VOID )
diff --git a/sc/source/ui/vba/vbaaxis.cxx b/sc/source/ui/vba/vbaaxis.cxx
index eeb830e..41ef215 100644
--- a/sc/source/ui/vba/vbaaxis.cxx
+++ b/sc/source/ui/vba/vbaaxis.cxx
@@ -588,7 +588,7 @@ ScVbaAxis::getScaleType( ) throw (script::BasicErrorException, uno::RuntimeExce
if (isValueAxis())
{
bool bisLogarithmic = false;
- mxPropertySet->getPropertyValue( OUString( OUString("Logarithmic")) ) >>= bisLogarithmic;
+ mxPropertySet->getPropertyValue( "Logarithmic" ) >>= bisLogarithmic;
if (bisLogarithmic)
nScaleType = xlScaleLogarithmic;
else
diff --git a/sc/source/ui/vba/vbaformat.cxx b/sc/source/ui/vba/vbaformat.cxx
index 342b0ce..5f0a6f5 100644
--- a/sc/source/ui/vba/vbaformat.cxx
+++ b/sc/source/ui/vba/vbaformat.cxx
@@ -105,7 +105,7 @@ ScVbaFormat< Ifc... >::setVerticalAlignment( const uno::Any& _oAlignment) thro
aVal = uno::makeAny( table::CellVertJustify2::STANDARD );
break;
}
- mxPropertySet->setPropertyValue( OUString( SC_UNONAME_CELLVJUS ), aVal );
+ mxPropertySet->setPropertyValue( SC_UNONAME_CELLVJUS, aVal );
}
catch (const uno::Exception&)
{
@@ -123,7 +123,7 @@ ScVbaFormat< Ifc... >::getVerticalAlignment( ) throw (script::BasicErrorExcepti
if (!isAmbiguous( OUString( SC_UNONAME_CELLVJUS ) ) )
{
sal_Int32 aAPIAlignment = table::CellVertJustify2::STANDARD;
- mxPropertySet->getPropertyValue( OUString( SC_UNONAME_CELLVJUS ) ) >>= aAPIAlignment;
+ mxPropertySet->getPropertyValue( SC_UNONAME_CELLVJUS ) >>= aAPIAlignment;
switch( aAPIAlignment )
{
case table::CellVertJustify2::BOTTOM:
@@ -181,7 +181,7 @@ ScVbaFormat< Ifc... >::setHorizontalAlignment( const uno::Any& HorizontalAlignme
// #FIXME what about the default case above?
// shouldn't need the test below
if ( aVal.hasValue() )
- mxPropertySet->setPropertyValue( OUString( SC_UNONAME_CELLHJUS ), aVal );
+ mxPropertySet->setPropertyValue( SC_UNONAME_CELLHJUS, aVal );
}
catch (const uno::Exception& )
{
@@ -248,7 +248,7 @@ ScVbaFormat< Ifc... >::setOrientation( const uno::Any& _aOrientation ) throw (sc
break;
case excel::XlOrientation::xlHorizontal:
aVal = uno::makeAny( table::CellOrientation_STANDARD );
- mxPropertySet->setPropertyValue( OUString( SC_UNONAME_ROTANG ), uno::makeAny( sal_Int32(0) ) );
+ mxPropertySet->setPropertyValue( SC_UNONAME_ROTANG, uno::makeAny( sal_Int32(0) ) );
break;
case excel::XlOrientation::xlUpward:
aVal = uno::makeAny( table::CellOrientation_BOTTOMTOP);
@@ -260,7 +260,7 @@ ScVbaFormat< Ifc... >::setOrientation( const uno::Any& _aOrientation ) throw (sc
// #FIXME what about the default case above?
// shouldn't need the test below
if ( aVal.hasValue() )
- mxPropertySet->setPropertyValue( OUString( SC_UNONAME_CELLORI ), aVal );
+ mxPropertySet->setPropertyValue( SC_UNONAME_CELLORI, aVal );
}
catch (const uno::Exception& )
@@ -278,7 +278,7 @@ ScVbaFormat< Ifc... >::getOrientation( ) throw (script::BasicErrorException, un
if (!isAmbiguous(OUString( SC_UNONAME_CELLORI )))
{
table::CellOrientation aOrientation = table::CellOrientation_STANDARD;
- if ( !( mxPropertySet->getPropertyValue( OUString( SC_UNONAME_CELLORI ) ) >>= aOrientation ) )
+ if ( !( mxPropertySet->getPropertyValue( SC_UNONAME_CELLORI ) >>= aOrientation ) )
throw uno::RuntimeException();
switch(aOrientation)
@@ -313,7 +313,7 @@ ScVbaFormat< Ifc... >::setWrapText( const uno::Any& _aWrapText ) throw (script::
{
try
{
- mxPropertySet->setPropertyValue( OUString( SC_UNONAME_WRAP ), _aWrapText);
+ mxPropertySet->setPropertyValue( SC_UNONAME_WRAP, _aWrapText);
}
catch (const uno::Exception& )
{
@@ -388,7 +388,7 @@ ScVbaFormat< Ifc... >::getNumberFormatLocal( ) throw (script::BasicErrorExcepti
throw uno::RuntimeException();
OUString sFormat;
- xNumberFormats->getByKey(nFormat)->getPropertyValue( OUString( FORMATSTRING )) >>= sFormat;
+ xNumberFormats->getByKey(nFormat)->getPropertyValue( FORMATSTRING ) >>= sFormat;
aRet = uno::makeAny( sFormat.toAsciiLowerCase() );
}
@@ -417,7 +417,7 @@ ScVbaFormat< Ifc... >::setNumberFormatLocal( const uno::Any& _oLocalFormatString
sLocalFormatString = sLocalFormatString.toAsciiUpperCase();
initializeNumberFormats();
lang::Locale aRangeLocale;
- xNumberFormats->getByKey(nFormat)->getPropertyValue( OUString( LOCALE ) ) >>= aRangeLocale;
+ xNumberFormats->getByKey(nFormat)->getPropertyValue( LOCALE ) >>= aRangeLocale;
sal_Int32 nNewFormat = xNumberFormats->queryKey(sLocalFormatString, aRangeLocale, sal_True);
if (nNewFormat == -1)
@@ -450,9 +450,9 @@ ScVbaFormat< Ifc... >::setNumberFormat( const uno::Any& _oFormatString ) throw (
nFormat = xNumberFormats->addNew(sFormatString, aDefaultLocale);
lang::Locale aRangeLocale;
- xNumberFormats->getByKey(nFormat)->getPropertyValue( OUString( LOCALE ) ) >>= aRangeLocale;
+ xNumberFormats->getByKey(nFormat)->getPropertyValue( LOCALE ) >>= aRangeLocale;
sal_Int32 nNewFormat = xNumberFormatTypes->getFormatForLocale(nFormat, aRangeLocale);
- mxPropertySet->setPropertyValue( OUString( SC_UNO_DP_NUMBERFO ), uno::makeAny( nNewFormat));
+ mxPropertySet->setPropertyValue( SC_UNO_DP_NUMBERFO, uno::makeAny( nNewFormat));
}
catch (const uno::Exception& )
{
@@ -477,7 +477,7 @@ ScVbaFormat< Ifc... >::setIndentLevel( const uno::Any& _aLevel ) throw (script::
throw uno::RuntimeException();
if (aAPIAlignment == table::CellHoriJustify_STANDARD)
mxPropertySet->setPropertyValue( sHoriJust, uno::makeAny( table::CellHoriJustify_LEFT) ) ;
- mxPropertySet->setPropertyValue( OUString( SC_UNONAME_PINDENT ), uno::makeAny( sal_Int16(nLevel * 352.8) ) );
+ mxPropertySet->setPropertyValue( SC_UNONAME_PINDENT, uno::makeAny( sal_Int16(nLevel * 352.8) ) );
}
catch (const uno::Exception&)
{
@@ -623,7 +623,7 @@ ScVbaFormat< Ifc... >::setShrinkToFit( const uno::Any& ShrinkToFit ) throw (scri
{
try
{
- mxPropertySet->setPropertyValue(OUString( SC_UNONAME_SHRINK_TO_FIT ), ShrinkToFit);
+ mxPropertySet->setPropertyValue( SC_UNONAME_SHRINK_TO_FIT, ShrinkToFit);
}
catch (const uno::Exception& )
{
@@ -674,7 +674,7 @@ ScVbaFormat< Ifc... >::setReadingOrder( const uno::Any& ReadingOrder ) throw (sc
default:
DebugHelper::basicexception(ERRCODE_BASIC_METHOD_FAILED, OUString());
}
- mxPropertySet->setPropertyValue( OUString( SC_UNONAME_WRITING ), aVal );
+ mxPropertySet->setPropertyValue( SC_UNONAME_WRITING, aVal );
}
catch (const uno::Exception& )
{
@@ -731,7 +731,7 @@ ScVbaFormat< Ifc... >::getNumberFormat( ) throw (script::BasicErrorException, u
sal_Int32 nNewFormat = xNumberFormatTypes->getFormatForLocale(nFormat, getDefaultLocale() );
OUString sFormat;
- xNumberFormats->getByKey(nNewFormat)->getPropertyValue( OUString( FORMATSTRING )) >>= sFormat;
+ xNumberFormats->getByKey(nNewFormat)->getPropertyValue( FORMATSTRING ) >>= sFormat;
aFormat = uno::makeAny( sFormat );
}
}
diff --git a/sc/source/ui/vba/vbawindow.cxx b/sc/source/ui/vba/vbawindow.cxx
index bdbebac..b18184d 100644
--- a/sc/source/ui/vba/vbawindow.cxx
+++ b/sc/source/ui/vba/vbawindow.cxx
@@ -340,7 +340,7 @@ ScVbaWindow::getCaption() throw (uno::RuntimeException, std::exception)
void SAL_CALL
ScVbaWindow::setCaption( const uno::Any& _caption ) throw (uno::RuntimeException, std::exception)
{
- getFrameProps()->setPropertyValue( OUString( SC_UNONAME_TITLE ), _caption );
+ getFrameProps()->setPropertyValue( SC_UNONAME_TITLE, _caption );
}
uno::Any SAL_CALL
diff --git a/sc/source/ui/vba/vbaworksheet.cxx b/sc/source/ui/vba/vbaworksheet.cxx
index e5e5730..f543602 100644
--- a/sc/source/ui/vba/vbaworksheet.cxx
+++ b/sc/source/ui/vba/vbaworksheet.cxx
@@ -161,8 +161,8 @@ openNewDoc(const OUString& aSheetName )
uno::Reference <frame::XDesktop2 > xComponentLoader = frame::Desktop::create(xContext);
uno::Reference<lang::XComponent > xComponent( xComponentLoader->loadComponentFromURL(
- OUString( "private:factory/scalc" ),
- OUString( "_blank" ), 0,
+ "private:factory/scalc",
+ "_blank", 0,
uno::Sequence < css::beans::PropertyValue >() ) );
uno::Reference <sheet::XSpreadsheetDocument> xSpreadDoc( xComponent, uno::UNO_QUERY_THROW );
if ( xSpreadDoc.is() )
diff --git a/sc/source/ui/view/cellsh2.cxx b/sc/source/ui/view/cellsh2.cxx
index 3000b75..578f47e 100644
--- a/sc/source/ui/view/cellsh2.cxx
+++ b/sc/source/ui/view/cellsh2.cxx
@@ -219,7 +219,7 @@ void ScCellShell::ExecuteDB( SfxRequest& rReq )
{
uno::Reference<frame::XFrame> xFrame = pViewFrame->GetFrame().GetFrameInterface();
uno::Reference<frame::XFrame> xBeamerFrame = xFrame->findFrame(
- OUString("_beamer"),
+ "_beamer",
frame::FrameSearchFlag::CHILDREN);
if ( xBeamerFrame.is() )
bWasOpen = true;
diff --git a/sc/source/ui/view/dbfunc3.cxx b/sc/source/ui/view/dbfunc3.cxx
index 2acb6b2..4e48e43 100644
--- a/sc/source/ui/view/dbfunc3.cxx
+++ b/sc/source/ui/view/dbfunc3.cxx
@@ -2029,7 +2029,7 @@ void ScDBFunc::ShowDataPilotSourceData( ScDPObject& rDPObj, const Sequence<sheet
if (!xPropSet.is())
continue;
- Any any = xPropSet->getPropertyValue( OUString(SC_UNO_DP_NUMBERFO) );
+ Any any = xPropSet->getPropertyValue( SC_UNO_DP_NUMBERFO );
sal_Int32 nNumFmt = 0;
if (!(any >>= nNumFmt))
continue;
diff --git a/sc/source/ui/view/viewfun5.cxx b/sc/source/ui/view/viewfun5.cxx
index ee60d8c..3e0f573 100644
--- a/sc/source/ui/view/viewfun5.cxx
+++ b/sc/source/ui/view/viewfun5.cxx
@@ -227,7 +227,7 @@ bool ScViewFunc::PasteDataFormat( SotClipboardFormatId nFormatId,
embed::InsertedObjectInfo aInfo = xClipboardCreator->createInstanceInitFromClipboard(
xTmpStor,
- OUString( "DummyName" ),
+ "DummyName",
uno::Sequence< beans::PropertyValue >() );
// TODO/LATER: in future InsertedObjectInfo will be used to get container related information
More information about the Libreoffice-commits
mailing list