tdf#88205 Adapt uses of css::uno::Sequence to use initializer_list ctor

in chart2 module

Change-Id: I9c6f2efd59b3796e0e6f5389467fe888f4465586
Reviewed-on: https://gerrit.libreoffice.org/27895
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
This commit is contained in:
Muhammet Kara 2016-08-05 11:49:02 +03:00 committed by Noel Grandin
parent 36d65037e7
commit e50a95b829
16 changed files with 27 additions and 49 deletions

View File

@ -81,8 +81,7 @@ css::uno::Sequence< OUString > SAL_CALL ChartFrameLoader::getSupportedServiceNam
uno::Sequence< OUString > ChartFrameLoader::getSupportedServiceNames_Static() uno::Sequence< OUString > ChartFrameLoader::getSupportedServiceNames_Static()
{ {
uno::Sequence<OUString> aSNS { CHART_FRAMELOADER_SERVICE_NAME }; return { CHART_FRAMELOADER_SERVICE_NAME };
return aSNS;
} }
// frame::XFrameLoader // frame::XFrameLoader

View File

@ -269,8 +269,7 @@ css::uno::Sequence< OUString > SAL_CALL ElementSelectorToolbarController::getSup
Sequence< OUString > ElementSelectorToolbarController::getSupportedServiceNames_Static() Sequence< OUString > ElementSelectorToolbarController::getSupportedServiceNames_Static()
{ {
Sequence<OUString> aServices { "com.sun.star.frame.ToolbarController" }; return { "com.sun.star.frame.ToolbarController" };
return aServices;
} }
ElementSelectorToolbarController::ElementSelectorToolbarController() ElementSelectorToolbarController::ElementSelectorToolbarController()
{ {

View File

@ -125,8 +125,7 @@ sal_Bool ChartToolbarController::supportsService(OUString const & ServiceName)
css::uno::Sequence<OUString> ChartToolbarController::getSupportedServiceNames() css::uno::Sequence<OUString> ChartToolbarController::getSupportedServiceNames()
throw (css::uno::RuntimeException, std::exception) throw (css::uno::RuntimeException, std::exception)
{ {
css::uno::Sequence<OUString> aServiceNames { "com.sun.star.frame.ToolbarController" }; return { "com.sun.star.frame.ToolbarController" };
return aServiceNames;
} }
} }

View File

@ -139,8 +139,7 @@ sal_Bool ChartPanelFactory::supportsService(OUString const & ServiceName)
css::uno::Sequence<OUString> ChartPanelFactory::getSupportedServiceNames() css::uno::Sequence<OUString> ChartPanelFactory::getSupportedServiceNames()
throw (css::uno::RuntimeException, std::exception) throw (css::uno::RuntimeException, std::exception)
{ {
css::uno::Sequence<OUString> aServiceNames { "com.sun.star.ui.UIElementFactory" }; return { "com.sun.star.ui.UIElementFactory" };
return aServiceNames;
} }
} } // end of namespace chart::sidebar } } // end of namespace chart::sidebar

View File

@ -82,8 +82,7 @@ uno::Reference< util::XCloneable > SAL_CALL CartesianCoordinateSystem::createClo
// ____ XServiceInfo ____ // ____ XServiceInfo ____
Sequence< OUString > CartesianCoordinateSystem::getSupportedServiceNames_Static() Sequence< OUString > CartesianCoordinateSystem::getSupportedServiceNames_Static()
{ {
Sequence<OUString> aServices { CHART2_COOSYSTEM_CARTESIAN_SERVICE_NAME }; return { CHART2_COOSYSTEM_CARTESIAN_SERVICE_NAME };
return aServices;
} }
// implement XServiceInfo methods basing upon getSupportedServiceNames_Static // implement XServiceInfo methods basing upon getSupportedServiceNames_Static

View File

@ -264,17 +264,14 @@ void Legend::fireModifyEvent()
Sequence< OUString > Legend::getSupportedServiceNames_Static() Sequence< OUString > Legend::getSupportedServiceNames_Static()
{ {
const sal_Int32 nNumServices( 6 ); return Sequence< OUString >{
sal_Int32 nI = 0; "com.sun.star.chart2.Legend",
Sequence< OUString > aServices( nNumServices ); "com.sun.star.beans.PropertySet",
aServices[ nI++ ] = "com.sun.star.chart2.Legend"; "com.sun.star.drawing.FillProperties",
aServices[ nI++ ] = "com.sun.star.beans.PropertySet"; "com.sun.star.drawing.LineProperties",
aServices[ nI++ ] = "com.sun.star.drawing.FillProperties"; "com.sun.star.style.CharacterProperties",
aServices[ nI++ ] = "com.sun.star.drawing.LineProperties"; "com.sun.star.layout.LayoutElement"
aServices[ nI++ ] = "com.sun.star.style.CharacterProperties"; };
aServices[ nI++ ] = "com.sun.star.layout.LayoutElement";
OSL_ASSERT( nNumServices == nI );
return aServices;
} }
// ____ OPropertySet ____ // ____ OPropertySet ____

View File

@ -82,8 +82,7 @@ uno::Reference< util::XCloneable > SAL_CALL PolarCoordinateSystem::createClone()
// ____ XServiceInfo ____ // ____ XServiceInfo ____
Sequence< OUString > PolarCoordinateSystem::getSupportedServiceNames_Static() Sequence< OUString > PolarCoordinateSystem::getSupportedServiceNames_Static()
{ {
Sequence<OUString> aServices { CHART2_COOSYSTEM_POLAR_SERVICE_NAME }; return { CHART2_COOSYSTEM_POLAR_SERVICE_NAME };
return aServices;
} }
// implement XServiceInfo methods basing upon getSupportedServiceNames_Static // implement XServiceInfo methods basing upon getSupportedServiceNames_Static

View File

@ -381,8 +381,7 @@ bool DataInterpreter::UseCategoriesAsX( const Sequence< beans::PropertyValue > &
Sequence< OUString > DataInterpreter::getSupportedServiceNames_Static() Sequence< OUString > DataInterpreter::getSupportedServiceNames_Static()
{ {
Sequence<OUString> aServices { "com.sun.star.chart2.DataInterpreter" }; return { "com.sun.star.chart2.DataInterpreter" };
return aServices;
} }
// implement XServiceInfo methods basing upon getSupportedServiceNames_Static // implement XServiceInfo methods basing upon getSupportedServiceNames_Static

View File

@ -168,8 +168,7 @@ void ConfigColorScheme::notify( const OUString & rPropertyName )
Sequence< OUString > ConfigColorScheme::getSupportedServiceNames_Static() Sequence< OUString > ConfigColorScheme::getSupportedServiceNames_Static()
{ {
Sequence<OUString> aServices { "com.sun.star.chart2.ColorScheme" }; return { "com.sun.star.chart2.ColorScheme" };
return aServices;
} }
// implement XServiceInfo methods basing upon getSupportedServiceNames_Static // implement XServiceInfo methods basing upon getSupportedServiceNames_Static

View File

@ -63,8 +63,7 @@ void SAL_CALL DataSource::setData( const Sequence< Reference< chart2::data::XLab
Sequence< OUString > DataSource::getSupportedServiceNames_Static() Sequence< OUString > DataSource::getSupportedServiceNames_Static()
{ {
Sequence<OUString> aServices { "com.sun.star.chart2.data.DataSource" }; return { "com.sun.star.chart2.data.DataSource" };
return aServices;
} }
OUString SAL_CALL DataSource::getImplementationName() OUString SAL_CALL DataSource::getImplementationName()

View File

@ -1547,8 +1547,7 @@ Reference< util::XCloneable > SAL_CALL InternalDataProvider::createClone()
Sequence< OUString > InternalDataProvider::getSupportedServiceNames_Static() Sequence< OUString > InternalDataProvider::getSupportedServiceNames_Static()
{ {
Sequence<OUString> aServices { "com.sun.star.chart2.data.DataProvider" }; return { "com.sun.star.chart2.data.DataProvider" };
return aServices;
} }
OUString SAL_CALL InternalDataProvider::getImplementationName() OUString SAL_CALL InternalDataProvider::getImplementationName()

View File

@ -151,8 +151,7 @@ void SAL_CALL LabeledDataSequence::removeModifyListener( const Reference< util::
Sequence< OUString > LabeledDataSequence::getSupportedServiceNames_Static() Sequence< OUString > LabeledDataSequence::getSupportedServiceNames_Static()
{ {
Sequence<OUString> aServices { "com.sun.star.chart2.data.LabeledDataSequence" }; return { "com.sun.star.chart2.data.LabeledDataSequence" };
return aServices;
} }
// implement XServiceInfo methods basing upon getSupportedServiceNames_Static // implement XServiceInfo methods basing upon getSupportedServiceNames_Static

View File

@ -73,8 +73,7 @@ sal_Bool SAL_CALL NameContainer::supportsService( const OUString& ServiceName )
Sequence< OUString > SAL_CALL NameContainer::getSupportedServiceNames() Sequence< OUString > SAL_CALL NameContainer::getSupportedServiceNames()
throw( css::uno::RuntimeException, std::exception ) throw( css::uno::RuntimeException, std::exception )
{ {
Sequence<OUString> aSNS { m_aServicename }; return { m_aServicename };
return aSNS;
} }
// XNameContainer // XNameContainer

View File

@ -78,8 +78,7 @@ OUString SAL_CALL LogarithmicScaling::getServiceName()
uno::Sequence< OUString > LogarithmicScaling::getSupportedServiceNames_Static() uno::Sequence< OUString > LogarithmicScaling::getSupportedServiceNames_Static()
{ {
uno::Sequence< OUString > aSeq { lcl_aServiceName_Logarithmic }; return { lcl_aServiceName_Logarithmic };
return aSeq;
} }
// implement XServiceInfo methods basing upon getSupportedServiceNames_Static // implement XServiceInfo methods basing upon getSupportedServiceNames_Static
@ -145,8 +144,7 @@ OUString SAL_CALL ExponentialScaling::getServiceName()
uno::Sequence< OUString > ExponentialScaling::getSupportedServiceNames_Static() uno::Sequence< OUString > ExponentialScaling::getSupportedServiceNames_Static()
{ {
uno::Sequence< OUString > aSeq { lcl_aServiceName_Exponential }; return { lcl_aServiceName_Exponential };
return aSeq;
} }
// implement XServiceInfo methods basing upon getSupportedServiceNames_Static // implement XServiceInfo methods basing upon getSupportedServiceNames_Static
@ -216,8 +214,7 @@ OUString SAL_CALL LinearScaling::getServiceName()
uno::Sequence< OUString > LinearScaling::getSupportedServiceNames_Static() uno::Sequence< OUString > LinearScaling::getSupportedServiceNames_Static()
{ {
uno::Sequence< OUString > aSeq { lcl_aServiceName_Linear }; return { lcl_aServiceName_Linear };
return aSeq;
} }
// implement XServiceInfo methods basing upon getSupportedServiceNames_Static // implement XServiceInfo methods basing upon getSupportedServiceNames_Static
@ -286,8 +283,7 @@ PowerScaling::getServiceName()
uno::Sequence< OUString > PowerScaling::getSupportedServiceNames_Static() uno::Sequence< OUString > PowerScaling::getSupportedServiceNames_Static()
{ {
uno::Sequence< OUString > aSeq { lcl_aServiceName_Power }; return { lcl_aServiceName_Power };
return aSeq;
} }
// implement XServiceInfo methods basing upon getSupportedServiceNames_Static // implement XServiceInfo methods basing upon getSupportedServiceNames_Static

View File

@ -106,8 +106,7 @@ OUString SAL_CALL DateScaling::getServiceName()
uno::Sequence< OUString > DateScaling::getSupportedServiceNames_Static() uno::Sequence< OUString > DateScaling::getSupportedServiceNames_Static()
{ {
uno::Sequence< OUString > aSeq { lcl_aServiceName_DateScaling }; return { lcl_aServiceName_DateScaling };
return aSeq;
} }
// implement XServiceInfo methods basing upon getSupportedServiceNames_Static // implement XServiceInfo methods basing upon getSupportedServiceNames_Static
@ -207,8 +206,7 @@ OUString SAL_CALL InverseDateScaling::getServiceName()
uno::Sequence< OUString > InverseDateScaling::getSupportedServiceNames_Static() uno::Sequence< OUString > InverseDateScaling::getSupportedServiceNames_Static()
{ {
uno::Sequence<OUString> aSeq { lcl_aServiceName_InverseDateScaling }; return { lcl_aServiceName_InverseDateScaling };
return aSeq;
} }
// implement XServiceInfo methods basing upon getSupportedServiceNames_Static // implement XServiceInfo methods basing upon getSupportedServiceNames_Static

View File

@ -1403,8 +1403,7 @@ css::uno::Sequence< OUString > SAL_CALL ChartView::getSupportedServiceNames()
uno::Sequence< OUString > ChartView::getSupportedServiceNames_Static() uno::Sequence< OUString > ChartView::getSupportedServiceNames_Static()
{ {
uno::Sequence<OUString> aSNS { CHART_VIEW_SERVICE_NAME }; return { CHART_VIEW_SERVICE_NAME };
return aSNS;
} }
::basegfx::B3DHomMatrix createTransformationSceneToScreen( ::basegfx::B3DHomMatrix createTransformationSceneToScreen(