diff options
author | Armin Le Grand (allotropia) <armin.le.grand.extern@allotropia.de> | 2023-05-12 15:32:51 +0200 |
---|---|---|
committer | Armin Le Grand <Armin.Le.Grand@me.com> | 2023-05-15 15:19:53 +0200 |
commit | 438f0752deaf7d6e6d9d1df381b64aca4628e944 (patch) | |
tree | f1907b25dad1cbf2604b16c657e11f5623c8b5b2 /chart2/source/controller | |
parent | efa965969c6d3dfe5745a535605a6b9a482a03bd (diff) |
MCGR: consolidations/cleanups for changes so far
Change-Id: I85cf40e4803b0485bb40349d8e81adc8123666c4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151706
Tested-by: Jenkins
Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
Diffstat (limited to 'chart2/source/controller')
-rw-r--r-- | chart2/source/controller/main/ChartController_Tools.cxx | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/chart2/source/controller/main/ChartController_Tools.cxx b/chart2/source/controller/main/ChartController_Tools.cxx index acc5dd950391..1a8f5071982f 100644 --- a/chart2/source/controller/main/ChartController_Tools.cxx +++ b/chart2/source/controller/main/ChartController_Tools.cxx @@ -74,7 +74,6 @@ #include <svx/unoapi.hxx> #include <svx/unopage.hxx> #include <svx/unoshape.hxx> -#include <svx/xgrad.hxx> #include <PropertyHelper.hxx> #include <LibreOfficeKit/LibreOfficeKitEnums.h> @@ -957,8 +956,8 @@ void ChartController::executeDispatch_FillColor(sal_uInt32 nColor) void ChartController::executeDispatch_FillGradient(std::u16string_view sJSONGradient) { - XGradient aXGradient = XGradient::fromJSON(sJSONGradient); - css::awt::Gradient aGradient = aXGradient.toGradientUNO(); + basegfx::BGradient aBGradient = basegfx::BGradient::fromJSON(sJSONGradient); + css::awt::Gradient aGradient = aBGradient.getAsGradient2(); try { @@ -973,9 +972,9 @@ void ChartController::executeDispatch_FillGradient(std::u16string_view sJSONGrad if( xPropSet.is() ) { OUString aPrefferedName = - OUString::number(static_cast<sal_Int32>(Color(aXGradient.GetColorStops().front().getStopColor()))) - + OUString::number(static_cast<sal_Int32>(Color(aXGradient.GetColorStops().back().getStopColor()))) - + OUString::number(static_cast<sal_Int32>(aXGradient.GetAngle().get())); + OUString::number(static_cast<sal_Int32>(Color(aBGradient.GetColorStops().front().getStopColor()))) + + OUString::number(static_cast<sal_Int32>(Color(aBGradient.GetColorStops().back().getStopColor()))) + + OUString::number(static_cast<sal_Int32>(aBGradient.GetAngle().get())); OUString aNewName = PropertyHelper::addGradientUniqueNameToTable(css::uno::Any(aGradient), xChartModel, |