diff options
Diffstat (limited to 'comphelper/source/misc')
-rw-r--r-- | comphelper/source/misc/documentinfo.cxx | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/comphelper/source/misc/documentinfo.cxx b/comphelper/source/misc/documentinfo.cxx index b63450590554..f0d2840d922a 100644 --- a/comphelper/source/misc/documentinfo.cxx +++ b/comphelper/source/misc/documentinfo.cxx @@ -157,6 +157,20 @@ namespace comphelper { return sTitle; } + void DocumentInfo::notifyMacroEventRead(const css::uno::Reference<css::frame::XModel>& rModel) + { + if (!rModel.is()) + return; + + // like BreakMacroSignature of XMLScriptContext use XModel::attachResource + // to propagate this notification + css::uno::Sequence<css::beans::PropertyValue> aMedDescr = rModel->getArgs(); + sal_Int32 nNewLen = aMedDescr.getLength() + 1; + aMedDescr.realloc(nNewLen); + aMedDescr[nNewLen-1].Name = "MacroEventRead"; + aMedDescr[nNewLen-1].Value <<= true; + rModel->attachResource(rModel->getURL(), aMedDescr); + } } // namespace comphelper |