From f16f35d40948bd4bbe835e0ba3c2f75aa0de23f7 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Sun, 31 Oct 2021 21:18:30 +0000 Subject: Related: tdf#145464 pass an explicit DocFrame for SID_SIGNATURE MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: I352e0d92720cd002cbe3f25d4fa0c07b69c88cf2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124535 Tested-by: Jenkins Reviewed-by: Caolán McNamara --- sfx2/source/doc/objserv.cxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'sfx2') diff --git a/sfx2/source/doc/objserv.cxx b/sfx2/source/doc/objserv.cxx index 6f7e3fc829b5..67de2f96a547 100644 --- a/sfx2/source/doc/objserv.cxx +++ b/sfx2/source/doc/objserv.cxx @@ -1512,14 +1512,14 @@ void SfxObjectShell::GetState_Impl(SfxItemSet &rSet) IMPL_LINK_NOARG(SfxObjectShell, SignDocumentHandler, weld::Button&, void) { - SfxViewFrame *pFrame = SfxViewFrame::GetFirst(this); - if (!pFrame) + SfxViewFrame* pViewFrm = SfxViewFrame::GetFirst(this); + if (!pViewFrm) { SAL_WARN("sfx.appl", "There should be some SfxViewFrame associated here"); return; } - pFrame->MakeActive_Impl(false); - GetDispatcher()->Execute(SID_SIGNATURE); + SfxUnoFrameItem aDocFrame(SID_FILLFRAME, pViewFrm->GetFrame().GetFrameInterface()); + pViewFrm->GetDispatcher()->ExecuteList(SID_SIGNATURE, SfxCallMode::SLOT, {}, { &aDocFrame }); } void SfxObjectShell::ExecProps_Impl(SfxRequest &rReq) -- cgit