summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--chart2/source/controller/sidebar/ChartColorWrapper.cxx14
1 files changed, 14 insertions, 0 deletions
diff --git a/chart2/source/controller/sidebar/ChartColorWrapper.cxx b/chart2/source/controller/sidebar/ChartColorWrapper.cxx
index b47d6fd6c2aa..aed95c711c21 100644
--- a/chart2/source/controller/sidebar/ChartColorWrapper.cxx
+++ b/chart2/source/controller/sidebar/ChartColorWrapper.cxx
@@ -14,6 +14,10 @@
#include <svx/tbcontrl.hxx>
+#include <comphelper/lok.hxx>
+#include <sfx2/viewsh.hxx>
+#include <LibreOfficeKit/LibreOfficeKitEnums.h>
+
namespace chart { namespace sidebar {
namespace {
@@ -109,6 +113,16 @@ void ChartColorWrapper::updateData()
aEvent.IsEnabled = true;
aEvent.State = xPropSet->getPropertyValue(maPropertyName);
mpControl->statusChanged(aEvent);
+
+ SfxViewShell* pViewShell = SfxViewShell::Current();
+ if (comphelper::LibreOfficeKit::isActive() && pViewShell && (maPropertyName == aLineColor))
+ {
+ std::string sCommand = OUStringToOString(aUrl.Complete, RTL_TEXTENCODING_ASCII_US).getStr();
+ sal_uInt32 nColor = -1;
+ aEvent.State >>= nColor;
+ pViewShell->libreOfficeKitViewCallback(LOK_CALLBACK_STATE_CHANGED,
+ (sCommand + "=" + std::to_string(nColor)).c_str());
+ }
}
} }