[Libreoffice-commits] core.git: Branch 'private/swe/libreoffice-5-2+backports' - chart2/source offapi/com offapi/UnoApi_offapi.mk sc/inc sc/source
Vasily Melenchuk
Vasily.Melenchuk at cib.de
Sat Jan 13 13:40:50 UTC 2018
chart2/source/controller/dialogs/Strings.src | 2 +-
chart2/source/controller/main/ChartController.cxx | 10 +++++-----
chart2/source/controller/main/ControllerCommandDispatch.cxx | 2 +-
offapi/UnoApi_offapi.mk | 2 +-
offapi/com/sun/star/chart2/XDataProviderAccess.idl | 6 ++++--
sc/inc/docuno.hxx | 6 +++---
sc/source/ui/unoobj/docuno.cxx | 6 +++---
7 files changed, 18 insertions(+), 16 deletions(-)
New commits:
commit 1b607acd8bfb895d821cda09128eb24a8e2ad80b
Author: Vasily Melenchuk <Vasily.Melenchuk at cib.de>
Date: Fri Jan 12 12:20:17 2018 +0300
tdf#113572: later upstream changes backport
Change-Id: I0cb73fb9299edbbd06f311a68a6534ad83b05728
Reviewed-on: https://gerrit.libreoffice.org/47790
Reviewed-by: Thorsten Behrens <Thorsten.Behrens at CIB.de>
Tested-by: Thorsten Behrens <Thorsten.Behrens at CIB.de>
diff --git a/chart2/source/controller/dialogs/Strings.src b/chart2/source/controller/dialogs/Strings.src
index 96f7f5598b2a..4567764656a4 100644
--- a/chart2/source/controller/dialogs/Strings.src
+++ b/chart2/source/controller/dialogs/Strings.src
@@ -36,7 +36,7 @@ String STR_DLG_STEPPED_LINE_PROPERTIES
String STR_DLG_REMOVE_DATA_TABLE
{
- Text [ en-US ] = "Do you want to delete data table and switch to data ranges?" ;
+ Text [ en-US ] = "This chart currently contains an internal data table. Do you want to proceed, deleting the internal data table, and set a new data range?" ;
};
String STR_PAGE_CHARTTYPE
diff --git a/chart2/source/controller/main/ChartController.cxx b/chart2/source/controller/main/ChartController.cxx
index f87f5c74f798..c19edd0bd471 100644
--- a/chart2/source/controller/main/ChartController.cxx
+++ b/chart2/source/controller/main/ChartController.cxx
@@ -66,7 +66,7 @@
#include <com/sun/star/ui/XSidebar.hpp>
#include <com/sun/star/chart2/XChartTypeContainer.hpp>
#include <com/sun/star/chart2/XCoordinateSystemContainer.hpp>
-#include <com/sun/star/chart2/XDataProviderCreator.hpp>
+#include <com/sun/star/chart2/XDataProviderAccess.hpp>
#include <svx/sidebar/SelectionChangeHandler.hxx>
#include <vcl/msgbox.hxx>
@@ -1407,7 +1407,7 @@ void ChartController::executeDispatch_SourceData()
{
// Check if we will able to create data provider later
Reference< lang::XServiceInfo > xParentServiceInfo( rModel.getParent(), uno::UNO_QUERY );
- if ( !xParentServiceInfo.is() || !xParentServiceInfo->supportsService("com.sun.star.chart2.XDataProviderCreator") )
+ if ( !xParentServiceInfo.is() || !xParentServiceInfo->supportsService("com.sun.star.chart2.XDataProviderAccess") )
return;
SolarMutexGuard aSolarGuard;
@@ -1422,14 +1422,14 @@ void ChartController::executeDispatch_SourceData()
rModel.removeDataProviders();
// Ask parent document to create new data provider
- css::uno::Reference< com::sun::star::chart2::XDataProviderCreator > xCreatorDoc(
+ css::uno::Reference< com::sun::star::chart2::XDataProviderAccess > xCreatorDoc(
rModel.getParent(), uno::UNO_QUERY );
- OSL_ENSURE( xCreatorDoc.is(), "Invalid XDataProviderCreator" );
+ SAL_WARN_IF( !xCreatorDoc.is(), "chart2.main", "Invalid XDataProviderAccess" );
if ( xCreatorDoc.is() )
{
uno::Reference< data::XDataProvider > xDataProvider = xCreatorDoc->createDataProvider();
- OSL_ENSURE( xCreatorDoc.is(), "Data provider was not created" );
+ SAL_WARN_IF( !xDataProvider.is(), "chart2.main", "Data provider was not created" );
if ( xDataProvider.is() )
{
rModel.attachDataProvider(xDataProvider);
diff --git a/chart2/source/controller/main/ControllerCommandDispatch.cxx b/chart2/source/controller/main/ControllerCommandDispatch.cxx
index 63e56bdeb156..cb0fb6f4a8ba 100644
--- a/chart2/source/controller/main/ControllerCommandDispatch.cxx
+++ b/chart2/source/controller/main/ControllerCommandDispatch.cxx
@@ -554,7 +554,7 @@ void ControllerCommandDispatch::updateCommandAvailability()
OSL_ENSURE(xParentServiceInfo.is(), "Invalid XServiceInfo");
if ( xParentServiceInfo.is() )
{
- bCanCreateDataProvider = xParentServiceInfo->supportsService("com.sun.star.chart2.XDataProviderCreator");
+ bCanCreateDataProvider = xParentServiceInfo->supportsService("com.sun.star.chart2.XDataProviderAccess");
}
}
}
diff --git a/offapi/UnoApi_offapi.mk b/offapi/UnoApi_offapi.mk
index 4b040db1d6e1..16015ebb772e 100644
--- a/offapi/UnoApi_offapi.mk
+++ b/offapi/UnoApi_offapi.mk
@@ -2030,7 +2030,7 @@ $(eval $(call gb_UnoApi_add_idlfiles,offapi,com/sun/star/chart2,\
XCoordinateSystem \
XCoordinateSystemContainer \
XDataInterpreter \
- XDataProviderCreator \
+ XDataProviderAccess \
XDataSeries \
XDataSeriesContainer \
XDefaultSizeTransmitter \
diff --git a/offapi/com/sun/star/chart2/XDataProviderCreator.idl b/offapi/com/sun/star/chart2/XDataProviderAccess.idl
similarity index 90%
rename from offapi/com/sun/star/chart2/XDataProviderCreator.idl
rename to offapi/com/sun/star/chart2/XDataProviderAccess.idl
index c7bac38e4b1d..3e0ebd16fdf3 100644
--- a/offapi/com/sun/star/chart2/XDataProviderCreator.idl
+++ b/offapi/com/sun/star/chart2/XDataProviderAccess.idl
@@ -26,10 +26,12 @@
module com { module sun { module star { module chart2 {
-/** creates a chart2 data provider for given document
+/** Provides access to chart2 data providers for a given document
+
+ @since LibreOffice 6.1
*/
-interface XDataProviderCreator : com::sun::star::uno::XInterface
+interface XDataProviderAccess : com::sun::star::uno::XInterface
{
/** creates a data provider for chart2
diff --git a/sc/inc/docuno.hxx b/sc/inc/docuno.hxx
index f9e01f60b323..15e870bf7706 100644
--- a/sc/inc/docuno.hxx
+++ b/sc/inc/docuno.hxx
@@ -38,7 +38,7 @@
#include <com/sun/star/sheet/XSpreadsheets2.hpp>
#include <com/sun/star/sheet/XDocumentAuditing.hpp>
#include <com/sun/star/chart2/data/XDataProvider.hpp>
-#include <com/sun/star/chart2/XDataProviderCreator.hpp>
+#include <com/sun/star/chart2/XDataProviderAccess.hpp>
#include <com/sun/star/lang/XServiceInfo.hpp>
#include <com/sun/star/util/XProtectable.hpp>
#include <com/sun/star/container/XEnumerationAccess.hpp>
@@ -87,7 +87,7 @@ class SC_DLLPUBLIC ScModelObj : public SfxBaseModel,
public SvxFmMSFactory, ///< derived from XMultiServiceFactory
public css::lang::XServiceInfo,
public css::util::XChangesNotifier,
- public css::chart2::XDataProviderCreator,
+ public css::chart2::XDataProviderAccess,
public css::sheet::opencl::XOpenCLSelection
{
private:
@@ -158,7 +158,7 @@ public:
virtual css::uno::Reference< css::sheet::XSpreadsheets > SAL_CALL
getSheets() throw(css::uno::RuntimeException, std::exception) override;
- /// XDataProviderCreator
+ /// XDataProviderAccess
virtual ::css::uno::Reference< css::chart2::data::XDataProvider > SAL_CALL
createDataProvider() throw (com::sun::star::uno::RuntimeException, std::exception) override;
diff --git a/sc/source/ui/unoobj/docuno.cxx b/sc/source/ui/unoobj/docuno.cxx
index 6837bc43a253..d31a0e01b330 100644
--- a/sc/source/ui/unoobj/docuno.cxx
+++ b/sc/source/ui/unoobj/docuno.cxx
@@ -218,7 +218,7 @@ using sc::TwipsToHMM;
#define SCMODELOBJ_SERVICE "com.sun.star.sheet.SpreadsheetDocument"
#define SCDOCSETTINGS_SERVICE "com.sun.star.sheet.SpreadsheetDocumentSettings"
#define SCDOC_SERVICE "com.sun.star.document.OfficeDocument"
-#define SCDATAPROVIDERCREATOR_SERVICE "com.sun.star.chart2.XDataProviderCreator"
+#define SCDATAPROVIDERACCESS_SERVICE "com.sun.star.chart2.XDataProviderAccess"
SC_SIMPLE_SERVICE_INFO( ScAnnotationsObj, "ScAnnotationsObj", "com.sun.star.sheet.CellAnnotations" )
SC_SIMPLE_SERVICE_INFO( ScDrawPagesObj, "ScDrawPagesObj", "com.sun.star.drawing.DrawPages" )
@@ -981,7 +981,7 @@ uno::Any SAL_CALL ScModelObj::queryInterface( const uno::Type& rType )
SC_QUERYINTERFACE( lang::XServiceInfo )
SC_QUERYINTERFACE( util::XChangesNotifier )
SC_QUERYINTERFACE( sheet::opencl::XOpenCLSelection )
- SC_QUERYINTERFACE( chart2::XDataProviderCreator )
+ SC_QUERYINTERFACE( chart2::XDataProviderAccess )
uno::Any aRet(SfxBaseModel::queryInterface( rType ));
if ( !aRet.hasValue()
@@ -2617,7 +2617,7 @@ uno::Sequence<OUString> SAL_CALL ScModelObj::getSupportedServiceNames()
aRet[0] = SCMODELOBJ_SERVICE;
aRet[1] = SCDOCSETTINGS_SERVICE;
aRet[2] = SCDOC_SERVICE;
- aRet[3] = SCDATAPROVIDERCREATOR_SERVICE;
+ aRet[3] = SCDATAPROVIDERACCESS_SERVICE;
return aRet;
}
More information about the Libreoffice-commits
mailing list