diff options
author | Szabolcs Dezsi <dezsiszabi@hotmail.com> | 2012-04-06 15:05:52 +0200 |
---|---|---|
committer | Jan Holesovsky <kendy@suse.cz> | 2012-04-06 15:07:41 +0200 |
commit | 743f22045c4ec08c46c259fc0ba240194a391457 (patch) | |
tree | faed42bb31c4ee767619eb5c3ebd4dec0a41fa03 /sw | |
parent | 0c6ebe5d225d6a655f078977455cec6d0a3afa6e (diff) |
Replaced equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(...)) with == operator
Pattern used:
find . -name "*.cxx" -exec sed -i 's/\( *\)\(else if\|if\) *( *\([^!()|&]*\)\.equalsAsciiL( *RTL_CONSTASCII_STRINGPARAM *( *\([^)]*\)) *) *)$/\1\2 ( \3 == \4 )/' \{\} \;
Diffstat (limited to 'sw')
-rw-r--r-- | sw/qa/extras/rtftok/rtftok.cxx | 8 | ||||
-rw-r--r-- | sw/source/core/edit/edlingu.cxx | 2 | ||||
-rw-r--r-- | sw/source/core/unocore/unochart.cxx | 10 | ||||
-rw-r--r-- | sw/source/core/unocore/unoobj.cxx | 14 | ||||
-rw-r--r-- | sw/source/core/unocore/unorefmk.cxx | 8 | ||||
-rw-r--r-- | sw/source/core/unocore/unostyle.cxx | 2 | ||||
-rw-r--r-- | sw/source/core/unocore/unotext.cxx | 2 | ||||
-rw-r--r-- | sw/source/filter/xml/xmlimp.cxx | 40 | ||||
-rw-r--r-- | sw/source/ui/app/docsh2.cxx | 4 | ||||
-rw-r--r-- | sw/source/ui/dbui/dbmgr.cxx | 12 | ||||
-rw-r--r-- | sw/source/ui/dbui/dbtablepreviewdialog.cxx | 2 | ||||
-rw-r--r-- | sw/source/ui/dbui/mailmergehelper.cxx | 2 | ||||
-rw-r--r-- | sw/source/ui/lingu/olmenu.cxx | 2 | ||||
-rw-r--r-- | sw/source/ui/uno/swdetect.cxx | 20 | ||||
-rw-r--r-- | sw/source/ui/vba/vbaheaderfooterhelper.cxx | 2 | ||||
-rw-r--r-- | sw/source/ui/vba/vbapagesetup.cxx | 4 | ||||
-rw-r--r-- | sw/source/ui/vba/vbatables.cxx | 2 | ||||
-rw-r--r-- | sw/source/ui/vba/vbaview.cxx | 8 |
18 files changed, 72 insertions, 72 deletions
diff --git a/sw/qa/extras/rtftok/rtftok.cxx b/sw/qa/extras/rtftok/rtftok.cxx index 926796799f82..a8908d5ad001 100644 --- a/sw/qa/extras/rtftok/rtftok.cxx +++ b/sw/qa/extras/rtftok/rtftok.cxx @@ -177,7 +177,7 @@ void RtfModelTest::testFdo45553() { uno::Reference<text::XTextRange> xRange(xRangeEnum->nextElement(), uno::UNO_QUERY); OUString aStr = xRange->getString(); - if (aStr.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("space-before"))) + if ( aStr == "space-before" ) { sal_Int32 nMargin = 0; uno::Reference<beans::XPropertySet> xPropertySet(xRange, uno::UNO_QUERY); @@ -185,7 +185,7 @@ void RtfModelTest::testFdo45553() aValue >>= nMargin; CPPUNIT_ASSERT_EQUAL(sal_Int32(TWIP_TO_MM100(120)), nMargin); } - else if (aStr.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("space-after"))) + else if ( aStr == "space-after" ) { sal_Int32 nMargin = 0; uno::Reference<beans::XPropertySet> xPropertySet(xRange, uno::UNO_QUERY); @@ -325,13 +325,13 @@ void RtfModelTest::testFdo46662() { const beans::PropertyValue& rProp = aProps[i]; - if (rProp.Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("ParentNumbering"))) + if ( rProp.Name == "ParentNumbering" ) { sal_Int16 nValue; rProp.Value >>= nValue; CPPUNIT_ASSERT_EQUAL(sal_Int16(2), nValue); } - else if (rProp.Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Suffix"))) + else if ( rProp.Name == "Suffix" ) { rtl::OUString sValue; rProp.Value >>= sValue; diff --git a/sw/source/core/edit/edlingu.cxx b/sw/source/core/edit/edlingu.cxx index b502d1220a01..96ca62708dc4 100644 --- a/sw/source/core/edit/edlingu.cxx +++ b/sw/source/core/edit/edlingu.cxx @@ -1752,7 +1752,7 @@ void SwSpellIter::CreatePortion(uno::Reference< XSpellAlternatives > xAlt, const beans::PropertyValue* pProperties = pGrammarResult->aProperties.getConstArray(); for( sal_Int32 nProp = 0; nProp < pGrammarResult->aProperties.getLength(); ++nProp ) { - if( pProperties->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("DialogTitle") ) ) + if ( pProperties->Name == "DialogTitle" ) { pProperties->Value >>= aPortion.sDialogTitle; break; diff --git a/sw/source/core/unocore/unochart.cxx b/sw/source/core/unocore/unochart.cxx index 76001036c10e..0b3796169d15 100644 --- a/sw/source/core/unocore/unochart.cxx +++ b/sw/source/core/unocore/unochart.cxx @@ -600,7 +600,7 @@ uno::Reference< chart2::data::XDataSource > SwChartDataProvider::Impl_createData const beans::PropertyValue *pArg = rArguments.getConstArray(); for (sal_Int32 i = 0; i < nArgs; ++i) { - if (pArg[i].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("DataRowSource"))) + if ( pArg[i].Name == "DataRowSource" ) { chart::ChartDataRowSource eSource; if (!(pArg[i].Value >>= eSource)) @@ -612,22 +612,22 @@ uno::Reference< chart2::data::XDataSource > SwChartDataProvider::Impl_createData } bDtaSrcIsColumns = eSource == chart::ChartDataRowSource_COLUMNS; } - else if (pArg[i].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("FirstCellAsLabel"))) + else if ( pArg[i].Name == "FirstCellAsLabel" ) { if (!(pArg[i].Value >>= bFirstIsLabel)) throw lang::IllegalArgumentException(); } - else if (pArg[i].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("CellRangeRepresentation"))) + else if ( pArg[i].Name == "CellRangeRepresentation" ) { if (!(pArg[i].Value >>= aRangeRepresentation)) throw lang::IllegalArgumentException(); } - else if (pArg[i].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("SequenceMapping"))) + else if ( pArg[i].Name == "SequenceMapping" ) { if (!(pArg[i].Value >>= aSequenceMapping)) throw lang::IllegalArgumentException(); } - else if (pArg[i].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("ChartOleObjectName"))) + else if ( pArg[i].Name == "ChartOleObjectName" ) { if (!(pArg[i].Value >>= aChartOleObjectName)) throw lang::IllegalArgumentException(); diff --git a/sw/source/core/unocore/unoobj.cxx b/sw/source/core/unocore/unoobj.cxx index e387015b62e0..2bf8ead309f6 100644 --- a/sw/source/core/unocore/unoobj.cxx +++ b/sw/source/core/unocore/unoobj.cxx @@ -2626,7 +2626,7 @@ sal_Bool SwUnoCursorHelper::ConvertSortProperties( const OUString& rPropName = pProperties[n].Name; // old and new sortdescriptor - if (rPropName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("IsSortInTable"))) + if ( rPropName == "IsSortInTable" ) { if (aValue.getValueType() == ::getBooleanCppuType()) { @@ -2637,7 +2637,7 @@ sal_Bool SwUnoCursorHelper::ConvertSortProperties( bRet = sal_False; } } - else if (rPropName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Delimiter"))) + else if ( rPropName == "Delimiter" ) { sal_Unicode uChar = sal_Unicode(); if (aValue >>= uChar) @@ -2650,7 +2650,7 @@ sal_Bool SwUnoCursorHelper::ConvertSortProperties( } } // old sortdescriptor - else if (rPropName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("SortColumns"))) + else if ( rPropName == "SortColumns" ) { bOldSortdescriptor = sal_True; sal_Bool bTemp(sal_False); @@ -2663,7 +2663,7 @@ sal_Bool SwUnoCursorHelper::ConvertSortProperties( bRet = sal_False; } } - else if ( rPropName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("IsCaseSensitive"))) + else if ( rPropName == "IsCaseSensitive" ) { bOldSortdescriptor = sal_True; sal_Bool bTemp(sal_False); @@ -2676,7 +2676,7 @@ sal_Bool SwUnoCursorHelper::ConvertSortProperties( bRet = sal_False; } } - else if (rPropName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("CollatorLocale"))) + else if ( rPropName == "CollatorLocale" ) { bOldSortdescriptor = sal_True; lang::Locale aLocale; @@ -2764,7 +2764,7 @@ sal_Bool SwUnoCursorHelper::ConvertSortProperties( } } // new sortdescriptor - else if (rPropName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("IsSortColumns"))) + else if ( rPropName == "IsSortColumns" ) { bNewSortdescriptor = sal_True; if (aValue.getValueType() == ::getBooleanCppuType()) @@ -2777,7 +2777,7 @@ sal_Bool SwUnoCursorHelper::ConvertSortProperties( bRet = sal_False; } } - else if (rPropName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("SortFields"))) + else if ( rPropName == "SortFields" ) { bNewSortdescriptor = sal_True; uno::Sequence < table::TableSortField > aFields; diff --git a/sw/source/core/unocore/unorefmk.cxx b/sw/source/core/unocore/unorefmk.cxx index 00b069c66971..088f5d24cf40 100644 --- a/sw/source/core/unocore/unorefmk.cxx +++ b/sw/source/core/unocore/unorefmk.cxx @@ -1441,7 +1441,7 @@ throw (beans::UnknownPropertyException, beans::PropertyVetoException, if (!pMeta) throw lang::DisposedException(); - if (rPropertyName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("NumberFormat"))) + if ( rPropertyName == "NumberFormat" ) { sal_Int32 nNumberFormat(0); if (rValue >>= nNumberFormat) @@ -1449,7 +1449,7 @@ throw (beans::UnknownPropertyException, beans::PropertyVetoException, pMeta->SetNumberFormat(static_cast<sal_uInt32>(nNumberFormat)); } } - else if (rPropertyName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("IsFixedLanguage"))) + else if ( rPropertyName == "IsFixedLanguage" ) { bool b(false); if (rValue >>= b) @@ -1476,12 +1476,12 @@ throw (beans::UnknownPropertyException, lang::WrappedTargetException, uno::Any any; - if (rPropertyName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("NumberFormat"))) + if ( rPropertyName == "NumberFormat" ) { const ::rtl::OUString text( getPresentation(sal_False) ); any <<= static_cast<sal_Int32>(pMeta->GetNumberFormat(text)); } - else if (rPropertyName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("IsFixedLanguage"))) + else if ( rPropertyName == "IsFixedLanguage" ) { any <<= pMeta->IsFixedLanguage(); } diff --git a/sw/source/core/unocore/unostyle.cxx b/sw/source/core/unocore/unostyle.cxx index f2f13313282e..93ad7961a24e 100644 --- a/sw/source/core/unocore/unostyle.cxx +++ b/sw/source/core/unocore/unostyle.cxx @@ -977,7 +977,7 @@ uno::Any SAL_CALL SwXStyleFamily::getPropertyValue( const ::rtl::OUString& sProp { uno::Any aRet; - if ( sPropertyName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("DisplayName") ) ) + if ( sPropertyName == "DisplayName" ) { SolarMutexGuard aGuard; sal_uInt32 nResId = 0; diff --git a/sw/source/core/unocore/unotext.cxx b/sw/source/core/unocore/unotext.cxx index c83d243c447b..cd7d061cfebe 100644 --- a/sw/source/core/unocore/unotext.cxx +++ b/sw/source/core/unocore/unotext.cxx @@ -2049,7 +2049,7 @@ lcl_ApplyCellProperties( { const OUString & rName = rCellProperties[nProperty].Name; const uno::Any & rValue = rCellProperties[nProperty].Value; - if (rName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("VerticalMerge"))) + if ( rName == "VerticalMerge" ) { // determine left border position // add the cell to a queue of merged cells diff --git a/sw/source/filter/xml/xmlimp.cxx b/sw/source/filter/xml/xmlimp.cxx index 6fa217848770..d20f738b127b 100644 --- a/sw/source/filter/xml/xmlimp.cxx +++ b/sw/source/filter/xml/xmlimp.cxx @@ -1233,45 +1233,45 @@ void SwXMLImport::SetConfigurationSettings(const Sequence < PropertyValue > & aC } // did we find any of the non-default cases? - if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("PrinterIndependentLayout")) ) + if ( pValues->Name == "PrinterIndependentLayout" ) bPrinterIndependentLayout = true; - else if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("AddExternalLeading")) ) + else if ( pValues->Name == "AddExternalLeading" ) bAddExternalLeading = true; - else if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("AddParaSpacingToTableCells")) ) + else if ( pValues->Name == "AddParaSpacingToTableCells" ) bAddParaSpacingToTableCells = true; - else if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("UseFormerLineSpacing")) ) + else if ( pValues->Name == "UseFormerLineSpacing" ) bUseFormerLineSpacing = true; - else if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("UseFormerObjectPositioning")) ) + else if ( pValues->Name == "UseFormerObjectPositioning" ) bUseFormerObjectPositioning = true; - else if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("UseFormerTextWrapping")) ) + else if ( pValues->Name == "UseFormerTextWrapping" ) bUseFormerTextWrapping = true; - else if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("UseOldNumbering")) ) + else if ( pValues->Name == "UseOldNumbering" ) bUseOldNumbering = true; - else if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("OutlineLevelYieldsNumbering")) ) + else if ( pValues->Name == "OutlineLevelYieldsNumbering" ) bOutlineLevelYieldsOutlineRule = true; - else if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("ConsiderTextWrapOnObjPos")) ) + else if ( pValues->Name == "ConsiderTextWrapOnObjPos" ) bConsiderWrapOnObjPos = true; - else if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("IgnoreFirstLineIndentInNumbering")) ) + else if ( pValues->Name == "IgnoreFirstLineIndentInNumbering" ) bIgnoreFirstLineIndentInNumbering = true; - else if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("DoNotJustifyLinesWithManualBreak")) ) + else if ( pValues->Name == "DoNotJustifyLinesWithManualBreak" ) bDoNotJustifyLinesWithManualBreak = true; - else if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("DoNotResetParaAttrsForNumFont")) ) + else if ( pValues->Name == "DoNotResetParaAttrsForNumFont" ) bDoNotResetParaAttrsForNumFont = true; - else if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("LoadReadonly")) ) + else if ( pValues->Name == "LoadReadonly" ) bLoadReadonly = true; - else if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("DoNotCaptureDrawObjsOnPage")) ) + else if ( pValues->Name == "DoNotCaptureDrawObjsOnPage" ) bDoNotCaptureDrawObjsOnPage = true; - else if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("ClipAsCharacterAnchoredWriterFlyFrames")) ) + else if ( pValues->Name == "ClipAsCharacterAnchoredWriterFlyFrames" ) bClipAsCharacterAnchoredWriterFlyFrames = true; - else if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("UnxForceZeroExtLeading")) ) + else if ( pValues->Name == "UnxForceZeroExtLeading" ) bUnixForceZeroExtLeading = true; - else if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("UseOldPrinterMetrics")) ) + else if ( pValues->Name == "UseOldPrinterMetrics" ) bUseOldPrinterMetrics = true; - else if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("SmallCapsPercentage66")) ) + else if ( pValues->Name == "SmallCapsPercentage66" ) bSmallCapsPercentage66 = true; - else if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("TabOverflow")) ) + else if ( pValues->Name == "TabOverflow" ) bTabOverflow = true; - else if( pValues->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("UnbreakableNumberings")) ) + else if ( pValues->Name == "UnbreakableNumberings" ) bUnbreakableNumberings = true; } catch( Exception& ) diff --git a/sw/source/ui/app/docsh2.cxx b/sw/source/ui/app/docsh2.cxx index 46cd7092d77f..54d39f910c85 100644 --- a/sw/source/ui/app/docsh2.cxx +++ b/sw/source/ui/app/docsh2.cxx @@ -1324,11 +1324,11 @@ void SwDocShell::Execute(SfxRequest& rReq) sal_Int32 nColonPos = sTmpl.indexOf( sal_Unicode(':') ); OUString sPrefix = sTmpl.copy( 0L, nColonPos ); - if( sPrefix.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Style"))) + if ( sPrefix == "Style" ) { aTemplateName = sTmpl.copy( 7L ); //get string behind "Style: " } - else if( sPrefix.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Outline"))) + else if ( sPrefix == "Outline" ) { nTemplateOutlineLevel = ( sTmpl.copy( 15L )).toInt32(); //get string behind "Outline: Leve "; bCreateByOutlineLevel = true; diff --git a/sw/source/ui/dbui/dbmgr.cxx b/sw/source/ui/dbui/dbmgr.cxx index 1e019e37d018..bc8b93b34af2 100644 --- a/sw/source/ui/dbui/dbmgr.cxx +++ b/sw/source/ui/dbui/dbmgr.cxx @@ -2561,17 +2561,17 @@ void SwNewDBMgr::InsertText(SwWrtShell& rSh, uno::Reference< XConnection> xConnection; for(sal_Int32 nPos = 0; nPos < rProperties.getLength(); nPos++) { - if(pValues[nPos].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(cDataSourceName))) + if ( pValues[nPos].Name == cDataSourceName ) pValues[nPos].Value >>= sDataSource; - else if(pValues[nPos].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(cCommand))) + else if ( pValues[nPos].Name == cCommand ) pValues[nPos].Value >>= sDataTableOrQuery; - else if(pValues[nPos].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(cCursor))) + else if ( pValues[nPos].Name == cCursor ) pValues[nPos].Value >>= xResSet; - else if(pValues[nPos].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(cSelection))) + else if ( pValues[nPos].Name == cSelection ) pValues[nPos].Value >>= aSelection; - else if(pValues[nPos].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(cCommandType))) + else if ( pValues[nPos].Name == cCommandType ) pValues[nPos].Value >>= nCmdType; - else if(pValues[nPos].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(cActiveConnection))) + else if ( pValues[nPos].Name == cActiveConnection ) pValues[nPos].Value >>= xConnection; } if(sDataSource.isEmpty() || sDataTableOrQuery.isEmpty() || !xResSet.is()) diff --git a/sw/source/ui/dbui/dbtablepreviewdialog.cxx b/sw/source/ui/dbui/dbtablepreviewdialog.cxx index 7cac4bff27af..fd976c85229a 100644 --- a/sw/source/ui/dbui/dbtablepreviewdialog.cxx +++ b/sw/source/ui/dbui/dbtablepreviewdialog.cxx @@ -68,7 +68,7 @@ SwDBTablePreviewDialog::SwDBTablePreviewDialog(Window* pParent, uno::Sequence< b const beans::PropertyValue* pValues = rValues.getConstArray(); for(sal_Int32 nValue = 0; nValue < rValues.getLength(); ++nValue ) { - if(pValues[nValue].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Command"))) + if ( pValues[nValue].Name == "Command" ) { String sDescription = m_aDescriptionFI.GetText(); OUString sTemp; diff --git a/sw/source/ui/dbui/mailmergehelper.cxx b/sw/source/ui/dbui/mailmergehelper.cxx index 9920f699cab9..b2058ad9edb8 100644 --- a/sw/source/ui/dbui/mailmergehelper.cxx +++ b/sw/source/ui/dbui/mailmergehelper.cxx @@ -770,7 +770,7 @@ uno::Any SwMailTransferable::getPropertyValue( const ::rtl::OUString& rPropertyN throw(beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException) { uno::Any aRet; - if( rPropertyName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("URL"))) + if ( rPropertyName == "URL" ) aRet <<= m_aURL; return aRet; } diff --git a/sw/source/ui/lingu/olmenu.cxx b/sw/source/ui/lingu/olmenu.cxx index 5e54f1055d61..6abb921c2a9d 100644 --- a/sw/source/ui/lingu/olmenu.cxx +++ b/sw/source/ui/lingu/olmenu.cxx @@ -586,7 +586,7 @@ aInfo16( SW_RES(IMG_INFO_16) ) sal_Int32 i = 0; while ( sExplanationLink.isEmpty() && i < aProperties.getLength() ) { - if ( aProperties[i].Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("FullCommentURL")) ) + if ( aProperties[i].Name == "FullCommentURL" ) { uno::Any aValue = aProperties[i].Value; aValue >>= sExplanationLink; diff --git a/sw/source/ui/uno/swdetect.cxx b/sw/source/ui/uno/swdetect.cxx index ff9af042063e..7552c080f49f 100644 --- a/sw/source/ui/uno/swdetect.cxx +++ b/sw/source/ui/uno/swdetect.cxx @@ -121,7 +121,7 @@ SwFilterDetect::~SwFilterDetect() for( sal_Int32 nProperty=0; nProperty<nPropertyCount; ++nProperty ) { // extract properties - if( lDescriptor[nProperty].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("URL")) ) + if ( lDescriptor[nProperty].Name == "URL" ) { lDescriptor[nProperty].Value >>= sTemp; aURL = sTemp; @@ -131,35 +131,35 @@ SwFilterDetect::~SwFilterDetect() lDescriptor[nProperty].Value >>= sTemp; aURL = sTemp; } - else if( lDescriptor[nProperty].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("TypeName")) ) + else if ( lDescriptor[nProperty].Name == "TypeName" ) { lDescriptor[nProperty].Value >>= sTemp; aTypeName = sTemp; } - else if( lDescriptor[nProperty].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("FilterName")) ) + else if ( lDescriptor[nProperty].Name == "FilterName" ) { lDescriptor[nProperty].Value >>= sTemp; aPreselectedFilterName = sTemp; } - else if( lDescriptor[nProperty].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("InputStream")) ) + else if ( lDescriptor[nProperty].Name == "InputStream" ) nIndexOfInputStream = nProperty; - else if( lDescriptor[nProperty].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("ReadOnly")) ) + else if ( lDescriptor[nProperty].Name == "ReadOnly" ) nIndexOfReadOnlyFlag = nProperty; - else if( lDescriptor[nProperty].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("UCBContent")) ) + else if ( lDescriptor[nProperty].Name == "UCBContent" ) nIndexOfContent = nProperty; - else if( lDescriptor[nProperty].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("AsTemplate")) ) + else if ( lDescriptor[nProperty].Name == "AsTemplate" ) { lDescriptor[nProperty].Value >>= bOpenAsTemplate; nIndexOfTemplateFlag = nProperty; } - else if( lDescriptor[nProperty].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("InteractionHandler")) ) + else if ( lDescriptor[nProperty].Name == "InteractionHandler" ) { lDescriptor[nProperty].Value >>= xInteraction; nIndexOfInteractionHandler = nProperty; } - else if( lDescriptor[nProperty].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("RepairPackage")) ) + else if ( lDescriptor[nProperty].Name == "RepairPackage" ) lDescriptor[nProperty].Value >>= bRepairPackage; - else if( lDescriptor[nProperty].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("DocumentTitle")) ) + else if ( lDescriptor[nProperty].Name == "DocumentTitle" ) nIndexOfDocumentTitle = nProperty; } diff --git a/sw/source/ui/vba/vbaheaderfooterhelper.cxx b/sw/source/ui/vba/vbaheaderfooterhelper.cxx index 2f7ee3f20959..8ea8db176ef6 100644 --- a/sw/source/ui/vba/vbaheaderfooterhelper.cxx +++ b/sw/source/ui/vba/vbaheaderfooterhelper.cxx @@ -52,7 +52,7 @@ sal_Bool HeaderFooterHelper::isHeaderFooter( const uno::Reference< text::XText > { uno::Reference< lang::XServiceInfo > xServiceInfo( xText, uno::UNO_QUERY_THROW ); rtl::OUString aImplName = xServiceInfo->getImplementationName(); - if( aImplName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("SwXHeadFootText")) ) + if ( aImplName == "SwXHeadFootText" ) return sal_True; return sal_False; } diff --git a/sw/source/ui/vba/vbapagesetup.cxx b/sw/source/ui/vba/vbapagesetup.cxx index 184ece7327b2..e7c17e5d4dd4 100644 --- a/sw/source/ui/vba/vbapagesetup.cxx +++ b/sw/source/ui/vba/vbapagesetup.cxx @@ -237,9 +237,9 @@ rtl::OUString SwVbaPageSetup::getStyleOfFirstPage() throw (uno::RuntimeException sal_Int32 wdSectionStart = word::WdSectionStart::wdSectionNewPage; uno::Reference< container::XNamed > xNamed( mxPageProps, uno::UNO_QUERY_THROW ); rtl::OUString sStyleName = xNamed->getName(); - if( sStyleName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Left Page")) ) + if ( sStyleName == "Left Page" ) wdSectionStart = word::WdSectionStart::wdSectionEvenPage; - else if( sStyleName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Right Page")) ) + else if ( sStyleName == "Right Page" ) wdSectionStart = word::WdSectionStart::wdSectionOddPage; else wdSectionStart = word::WdSectionStart::wdSectionNewPage; diff --git a/sw/source/ui/vba/vbatables.cxx b/sw/source/ui/vba/vbatables.cxx index 917d7d0e6adc..862dd9df6338 100644 --- a/sw/source/ui/vba/vbatables.cxx +++ b/sw/source/ui/vba/vbatables.cxx @@ -36,7 +36,7 @@ sal_Bool lcl_isInHeaderFooter( const uno::Reference< text::XTextTable >& xTable uno::Reference< text::XText > xText = xTextContent->getAnchor()->getText(); uno::Reference< lang::XServiceInfo > xServiceInfo( xText, uno::UNO_QUERY_THROW ); rtl::OUString aImplName = xServiceInfo->getImplementationName(); - if( aImplName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("SwXHeadFootText")) ) + if ( aImplName == "SwXHeadFootText" ) return sal_True; return sal_False; } diff --git a/sw/source/ui/vba/vbaview.cxx b/sw/source/ui/vba/vbaview.cxx index 2b8d3d1124c7..95b21c29a177 100644 --- a/sw/source/ui/vba/vbaview.cxx +++ b/sw/source/ui/vba/vbaview.cxx @@ -87,11 +87,11 @@ SwVbaView::getSeekView() throw (css::uno::RuntimeException) } uno::Reference< lang::XServiceInfo > xServiceInfo( xCurrentText, uno::UNO_QUERY_THROW ); rtl::OUString aImplName = xServiceInfo->getImplementationName(); - if( aImplName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("SwXBodyText")) ) + if ( aImplName == "SwXBodyText" ) { return word::WdSeekView::wdSeekMainDocument; } - else if( aImplName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("SwXHeadFootText")) ) + else if ( aImplName == "SwXHeadFootText" ) { if( HeaderFooterHelper::isHeader( mxModel ) ) { @@ -112,7 +112,7 @@ SwVbaView::getSeekView() throw (css::uno::RuntimeException) return word::WdSeekView::wdSeekPrimaryFooter; } } - else if( aImplName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("SwXFootnote")) ) + else if ( aImplName == "SwXFootnote" ) { if( xServiceInfo->supportsService( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("com.sun.star.text.Endnote") ) ) ) return word::WdSeekView::wdSeekEndnotes; @@ -313,7 +313,7 @@ uno::Reference< text::XTextRange > SwVbaView::getHFTextRange( sal_Int32 nType ) uno::Reference< beans::XPropertySet > xCursorProps( mxViewCursor, uno::UNO_QUERY_THROW ); rtl::OUString aPageStyleName; xCursorProps->getPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("PageStyleName"))) >>= aPageStyleName; - if( aPageStyleName.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("First Page")) ) + if ( aPageStyleName == "First Page" ) { // go to the beginning of where the next style is used sal_Bool hasNextPage = sal_False; |