summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
Diffstat (limited to 'sc')
-rw-r--r--sc/source/ui/inc/gridwin.hxx1
-rw-r--r--sc/source/ui/view/gridwin.cxx14
-rw-r--r--sc/source/ui/view/tabview3.cxx1
3 files changed, 16 insertions, 0 deletions
diff --git a/sc/source/ui/inc/gridwin.hxx b/sc/source/ui/inc/gridwin.hxx
index 8bdee8a55190..a3ddbc84bac1 100644
--- a/sc/source/ui/inc/gridwin.hxx
+++ b/sc/source/ui/inc/gridwin.hxx
@@ -475,6 +475,7 @@ public:
virtual FactoryFunction GetUITestFactory() const override;
void updateLOKValListButton(bool bVisible, const ScAddress& rPos) const;
+ void updateLOKInputHelp(const OUString& title, const OUString& content) const;
protected:
void ImpCreateOverlayObjects();
diff --git a/sc/source/ui/view/gridwin.cxx b/sc/source/ui/view/gridwin.cxx
index 7ee10d644e9e..e858a9337041 100644
--- a/sc/source/ui/view/gridwin.cxx
+++ b/sc/source/ui/view/gridwin.cxx
@@ -137,6 +137,7 @@
#include <LibreOfficeKit/LibreOfficeKitEnums.h>
#include <vector>
+#include <boost/property_tree/json_parser.hpp>
using namespace css;
using namespace css::uno;
@@ -4730,6 +4731,19 @@ void ScGridWindow::UpdateAutoFillMark(bool bMarked, const ScRange& rMarkRange)
}
}
+void ScGridWindow::updateLOKInputHelp(const OUString& title, const OUString& content) const
+{
+ ScTabViewShell* pViewShell = pViewData->GetViewShell();
+
+ boost::property_tree::ptree aTree;
+ aTree.put("title", title);
+ aTree.put("content", content);
+
+ std::stringstream aStream;
+ boost::property_tree::write_json(aStream, aTree);
+ pViewShell->libreOfficeKitViewCallback(LOK_CALLBACK_VALIDITY_INPUT_HELP, aStream.str().c_str());
+}
+
void ScGridWindow::updateLOKValListButton( bool bVisible, const ScAddress& rPos ) const
{
SCCOL nX = rPos.Col();
diff --git a/sc/source/ui/view/tabview3.cxx b/sc/source/ui/view/tabview3.cxx
index 30986e02d044..ace30689b743 100644
--- a/sc/source/ui/view/tabview3.cxx
+++ b/sc/source/ui/view/tabview3.cxx
@@ -833,6 +833,7 @@ void ScTabView::TestHintWindow()
if (pWindow == pWin)
{
xOverlayManager->add(*pOverlay);
+ pWindow->updateLOKInputHelp(aTitle, aMessage);
}
else
{