svx/source/form/datanavi.cxx | 11 +++-------- svx/source/form/fmcontrollayout.cxx | 4 +--- svx/source/form/fmshimp.cxx | 4 ++-- svx/source/form/formcontroller.cxx | 4 ++-- svx/source/gallery2/galbrws2.cxx | 4 ++-- svx/source/svdraw/svdouno.cxx | 5 +---- svx/source/tbxctrls/tbcontrl.cxx | 8 +++----- svx/source/xml/xmleohlp.cxx | 2 +- svx/source/xml/xmlxtexp.cxx | 10 +++------- 9 files changed, 18 insertions(+), 34 deletions(-)
New commits: commit bdffd36de86d37124fb49d8cadea8b5e03c1bf34 Author: Noel Grandin <n...@peralex.com> Date: Wed Nov 4 11:31:17 2015 +0200 loplugin:stringconstant Change-Id: Iff0ab7716d76dc44693fca49d341a6fd88b89b01 diff --git a/svx/source/form/datanavi.cxx b/svx/source/form/datanavi.cxx index b675f7e..2ed4ce5 100644 --- a/svx/source/form/datanavi.cxx +++ b/svx/source/form/datanavi.cxx @@ -1525,9 +1525,7 @@ namespace svxform xUIHelper->newModel( m_xFrameModel, sNewName ), UNO_SET_THROW ); Reference< XPropertySet > xModelProps( xNewModel, UNO_QUERY_THROW ); - xModelProps->setPropertyValue( - OUString( "ExternalData" ), - makeAny( !bDocumentData ) ); + xModelProps->setPropertyValue("ExternalData", makeAny( !bDocumentData ) ); sal_Int32 nNewPos = m_pModelsBox->InsertEntry( sNewName ); m_pModelsBox->SelectEntryPos( nNewPos ); @@ -1554,8 +1552,7 @@ namespace svxform Reference< XNameContainer > xXForms( xFormsSupp->getXForms(), UNO_SET_THROW ); Reference< XPropertySet > xModelProps( xXForms->getByName( sSelectedModel ), UNO_QUERY_THROW ); bool bExternalData = false; - OSL_VERIFY( xModelProps->getPropertyValue( - OUString( "ExternalData" ) ) >>= bExternalData ); + OSL_VERIFY( xModelProps->getPropertyValue( "ExternalData" ) >>= bExternalData ); bDocumentData = !bExternalData; } catch( const Exception& ) @@ -1574,9 +1571,7 @@ namespace svxform Reference< css::xforms::XFormsSupplier > xFormsSupp( m_xFrameModel, UNO_QUERY_THROW ); Reference< XNameContainer > xXForms( xFormsSupp->getXForms(), UNO_SET_THROW ); Reference< XPropertySet > xModelProps( xXForms->getByName( sSelectedModel ), UNO_QUERY_THROW ); - xModelProps->setPropertyValue( - OUString( "ExternalData" ), - makeAny( !bDocumentData ) ); + xModelProps->setPropertyValue( "ExternalData", makeAny( !bDocumentData ) ); bIsDocModified = true; } catch( const Exception& ) diff --git a/svx/source/form/fmcontrollayout.cxx b/svx/source/form/fmcontrollayout.cxx index fecbb23..85061c8 100644 --- a/svx/source/form/fmcontrollayout.cxx +++ b/svx/source/form/fmcontrollayout.cxx @@ -186,9 +186,7 @@ namespace svxform // retrieve a default font for this locale, and set it at the control vcl::Font aFont = OutputDevice::GetDefaultFont( DefaultFontType::SANS, LanguageTag::convertToLanguageType( aDocumentCharLocale ), GetDefaultFontFlags::OnlyOne ); FontDescriptor aFontDesc = VCLUnoHelper::CreateFontDescriptor( aFont ); - _rxModel->setPropertyValue( - OUString( "FontDescriptor" ), - makeAny( aFontDesc ) + _rxModel->setPropertyValue("FontDescriptor", makeAny( aFontDesc ) ); } catch( const Exception& ) diff --git a/svx/source/form/fmshimp.cxx b/svx/source/form/fmshimp.cxx index cf32940..09e5ac2 100644 --- a/svx/source/form/fmshimp.cxx +++ b/svx/source/form/fmshimp.cxx @@ -2967,7 +2967,7 @@ void FmXFormShell::startFiltering() { Reference< XModeSelector> xModeSelector(*j, UNO_QUERY); if (xModeSelector.is()) - xModeSelector->setMode( OUString( "FilterMode" ) ); + xModeSelector->setMode( "FilterMode" ); } } @@ -3073,7 +3073,7 @@ void FmXFormShell::stopFiltering(bool bSave) Reference< XModeSelector> xModeSelector(*j, UNO_QUERY); if (xModeSelector.is()) - xModeSelector->setMode( OUString( "DataMode" ) ); + xModeSelector->setMode( "DataMode" ); } if (bSave) // execute the filter { diff --git a/svx/source/form/formcontroller.cxx b/svx/source/form/formcontroller.cxx index 4226e17..7956ba1 100644 --- a/svx/source/form/formcontroller.cxx +++ b/svx/source/form/formcontroller.cxx @@ -3261,7 +3261,7 @@ void FormController::startFiltering() Reference< XModeSelector > xSelector(xControl, UNO_QUERY); if (xSelector.is()) { - xSelector->setMode( OUString( "FilterMode" ) ); + xSelector->setMode( "FilterMode" ); // listening for new controls of the selector Reference< XContainer > xContainer(xSelector, UNO_QUERY); @@ -3387,7 +3387,7 @@ void FormController::stopFiltering() Reference< XModeSelector > xSelector(xControl, UNO_QUERY); if (xSelector.is()) { - xSelector->setMode( OUString( "DataMode" ) ); + xSelector->setMode( "DataMode" ); // listening for new controls of the selector Reference< XContainer > xContainer(xSelector, UNO_QUERY); diff --git a/svx/source/gallery2/galbrws2.cxx b/svx/source/gallery2/galbrws2.cxx index 0d47121..d2e6989 100644 --- a/svx/source/gallery2/galbrws2.cxx +++ b/svx/source/gallery2/galbrws2.cxx @@ -312,7 +312,7 @@ void GalleryThemePopup::ExecutePopup( vcl::Window *pWindow, const ::Point &aPos { rCmdInfo.Dispatch = xDispatchProvider->queryDispatch( rCmdInfo.URL, - OUString( "_self" ), + "_self", css::frame::FrameSearchFlag::SELF ); } @@ -1069,7 +1069,7 @@ void GalleryBrowser2::Dispatch( m_xTransformer->parseStrict( aURL ); xDispatch = xDispatchProvider->queryDispatch( aURL, - OUString( "_self" ), + "_self", css::frame::FrameSearchFlag::SELF ); } diff --git a/svx/source/svdraw/svdouno.cxx b/svx/source/svdraw/svdouno.cxx index ed5326a..b430648 100644 --- a/svx/source/svdraw/svdouno.cxx +++ b/svx/source/svdraw/svdouno.cxx @@ -239,10 +239,7 @@ void SdrUnoObj::SetContextWritingMode( const sal_Int16 _nContextWritingMode ) try { uno::Reference< beans::XPropertySet > xModelProperties( GetUnoControlModel(), uno::UNO_QUERY_THROW ); - xModelProperties->setPropertyValue( - OUString( "ContextWritingMode" ), - uno::makeAny( _nContextWritingMode ) - ); + xModelProperties->setPropertyValue( "ContextWritingMode", uno::makeAny( _nContextWritingMode ) ); } catch( const uno::Exception& ) { diff --git a/svx/source/tbxctrls/tbcontrl.cxx b/svx/source/tbxctrls/tbcontrl.cxx index 3c2eb62..0d0ea9d 100644 --- a/svx/source/tbxctrls/tbcontrl.cxx +++ b/svx/source/tbxctrls/tbcontrl.cxx @@ -2051,8 +2051,8 @@ struct SvxStyleToolBoxControl::Impl } else if( ( - bSpecModeCalc = xServices->supportsService(OUString( - "com.sun.star.sheet.SpreadsheetDocument")))) + bSpecModeCalc = xServices->supportsService( + "com.sun.star.sheet.SpreadsheetDocument"))) { static const sal_Char* aCalcStyles[] = { @@ -2062,9 +2062,7 @@ struct SvxStyleToolBoxControl::Impl "Result2" }; Reference<container::XNameAccess> xCellStyles; - xStylesSupplier->getStyleFamilies()->getByName( - OUString("CellStyles")) >>= - xCellStyles; + xStylesSupplier->getStyleFamilies()->getByName("CellStyles") >>= xCellStyles; for( sal_uInt32 nStyle = 0; nStyle < sizeof( aCalcStyles ) / sizeof( sal_Char*); ++nStyle ) { try diff --git a/svx/source/xml/xmleohlp.cxx b/svx/source/xml/xmleohlp.cxx index 4e9b873..20fc5b8 100644 --- a/svx/source/xml/xmleohlp.cxx +++ b/svx/source/xml/xmleohlp.cxx @@ -413,7 +413,7 @@ bool SvXMLEmbeddedObjectHelper::ImplReadObject( // This is an ole object uno::Reference< beans::XPropertySet > xProps( xStm, uno::UNO_QUERY_THROW ); xProps->setPropertyValue( - OUString( "MediaType" ), + "MediaType", uno::makeAny( OUString( "application/vnd.sun.star.oleobject" ) ) ); xStm->getOutputStream()->closeOutput(); diff --git a/svx/source/xml/xmlxtexp.cxx b/svx/source/xml/xmlxtexp.cxx index 15b15cb..bc56e50 100644 --- a/svx/source/xml/xmlxtexp.cxx +++ b/svx/source/xml/xmlxtexp.cxx @@ -177,14 +177,10 @@ static void initializeStreamMetadata( const uno::Reference< uno::XInterface > &x try { - xProps->setPropertyValue( - OUString( "MediaType" ), - uno::makeAny( OUString( "text/xml" ) ) ); + xProps->setPropertyValue("MediaType", uno::makeAny( OUString( "text/xml" ) ) ); // use stock encryption - xProps->setPropertyValue( - OUString( "UseCommonStoragePasswordEncryption" ), - uno::makeAny( sal_True ) ); + xProps->setPropertyValue("UseCommonStoragePasswordEncryption", uno::makeAny( sal_True ) ); } catch ( const uno::Exception & ) { OSL_FAIL( "exception setting stream metadata" ); @@ -197,7 +193,7 @@ static void createStorageStream( uno::Reference < io::XOutputStream > *xOut, { uno::Reference < io::XStream > xStream; xStream = xSubStorage->openStreamElement( - OUString( "Content.xml" ), + "Content.xml", embed::ElementModes::WRITE ); *ppGraphicHelper = SvXMLGraphicHelper::Create( xSubStorage, GRAPHICHELPER_MODE_WRITE ); initializeStreamMetadata( xStream ); _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits