From fc9c196df1fabcf71637cf10f63a87be65071056 Mon Sep 17 00:00:00 2001 From: Markus Mohrhard Date: Sun, 9 Mar 2014 19:15:44 +0100 Subject: add property mapping to a few more chart types Change-Id: If02f865741524f74277b77615dea1bc71fb576eb --- chart2/source/model/template/BarChartType.cxx | 10 ++++++++++ chart2/source/model/template/BarChartType.hxx | 3 +++ chart2/source/model/template/ColumnChartType.cxx | 10 ++++++++++ chart2/source/model/template/ColumnChartType.hxx | 3 +++ chart2/source/model/template/PieChartType.cxx | 10 ++++++++++ chart2/source/model/template/PieChartType.hxx | 3 +++ 6 files changed, 39 insertions(+) (limited to 'chart2') diff --git a/chart2/source/model/template/BarChartType.cxx b/chart2/source/model/template/BarChartType.cxx index 2645c6c412c3..00c0e53a6f8d 100644 --- a/chart2/source/model/template/BarChartType.cxx +++ b/chart2/source/model/template/BarChartType.cxx @@ -53,6 +53,16 @@ OUString SAL_CALL BarChartType::getChartType() return CHART2_SERVICE_NAME_CHARTTYPE_BAR; } +uno::Sequence< OUString > BarChartType::getSupportedPropertyRoles() + throw (uno::RuntimeException, std::exception) +{ + uno::Sequence< OUString > aPropRoles(2); + aPropRoles[0] = "FillColor"; + aPropRoles[1] = "BorderColor"; + + return aPropRoles; +} + uno::Sequence< OUString > BarChartType::getSupportedServiceNames_Static() { uno::Sequence< OUString > aServices( 2 ); diff --git a/chart2/source/model/template/BarChartType.hxx b/chart2/source/model/template/BarChartType.hxx index e04e882aec9d..4f6c980370f4 100644 --- a/chart2/source/model/template/BarChartType.hxx +++ b/chart2/source/model/template/BarChartType.hxx @@ -44,6 +44,9 @@ protected: // ____ XChartType ____ virtual OUString SAL_CALL getChartType() throw (::com::sun::star::uno::RuntimeException, std::exception); + virtual com::sun::star::uno::Sequence< OUString > SAL_CALL + getSupportedPropertyRoles() + throw (::com::sun::star::uno::RuntimeException, std::exception); // ____ XCloneable ____ virtual ::com::sun::star::uno::Reference< ::com::sun::star::util::XCloneable > SAL_CALL createClone() diff --git a/chart2/source/model/template/ColumnChartType.cxx b/chart2/source/model/template/ColumnChartType.cxx index ccc0563788de..4357b6a995fd 100644 --- a/chart2/source/model/template/ColumnChartType.cxx +++ b/chart2/source/model/template/ColumnChartType.cxx @@ -152,6 +152,16 @@ OUString SAL_CALL ColumnChartType::getChartType() return CHART2_SERVICE_NAME_CHARTTYPE_COLUMN; } +uno::Sequence< OUString > ColumnChartType::getSupportedPropertyRoles() + throw (uno::RuntimeException, std::exception) +{ + uno::Sequence< OUString > aPropRoles(2); + aPropRoles[0] = "FillColor"; + aPropRoles[1] = "BorderColor"; + + return aPropRoles; +} + // ____ OPropertySet ____ uno::Any ColumnChartType::GetDefaultValue( sal_Int32 nHandle ) const throw(beans::UnknownPropertyException) diff --git a/chart2/source/model/template/ColumnChartType.hxx b/chart2/source/model/template/ColumnChartType.hxx index 3a03bba568c3..dcfdf3e76b17 100644 --- a/chart2/source/model/template/ColumnChartType.hxx +++ b/chart2/source/model/template/ColumnChartType.hxx @@ -44,6 +44,9 @@ protected: // ____ XChartType ____ virtual OUString SAL_CALL getChartType() throw (::com::sun::star::uno::RuntimeException, std::exception); + virtual com::sun::star::uno::Sequence< OUString > SAL_CALL + getSupportedPropertyRoles() + throw (::com::sun::star::uno::RuntimeException, std::exception); // ____ OPropertySet ____ virtual ::com::sun::star::uno::Any GetDefaultValue( sal_Int32 nHandle ) const diff --git a/chart2/source/model/template/PieChartType.cxx b/chart2/source/model/template/PieChartType.cxx index 8fdd25d559c2..101335923bcb 100644 --- a/chart2/source/model/template/PieChartType.cxx +++ b/chart2/source/model/template/PieChartType.cxx @@ -195,6 +195,16 @@ Reference< chart2::XCoordinateSystem > SAL_CALL return xResult; } +uno::Sequence< OUString > PieChartType::getSupportedPropertyRoles() + throw (uno::RuntimeException, std::exception) +{ + uno::Sequence< OUString > aPropRoles(2); + aPropRoles[0] = "FillColor"; + aPropRoles[1] = "BorderColor"; + + return aPropRoles; +} + // ____ OPropertySet ____ uno::Any PieChartType::GetDefaultValue( sal_Int32 nHandle ) const throw(beans::UnknownPropertyException) diff --git a/chart2/source/model/template/PieChartType.hxx b/chart2/source/model/template/PieChartType.hxx index aefd34cbaed9..c4bdfc183be9 100644 --- a/chart2/source/model/template/PieChartType.hxx +++ b/chart2/source/model/template/PieChartType.hxx @@ -49,6 +49,9 @@ protected: createCoordinateSystem( ::sal_Int32 DimensionCount ) throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException, std::exception); + virtual com::sun::star::uno::Sequence< OUString > SAL_CALL + getSupportedPropertyRoles() + throw (::com::sun::star::uno::RuntimeException, std::exception); // ____ OPropertySet ____ virtual ::com::sun::star::uno::Any GetDefaultValue( sal_Int32 nHandle ) const -- cgit