summaryrefslogtreecommitdiff
path: root/include/sfx2
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.com>2024-09-05 14:44:48 +0200
committerMiklos Vajna <vmiklos@collabora.com>2024-09-05 16:14:25 +0200
commit0255283974894f5ad9ba92c3a52912657ed4bdf6 (patch)
treebbe84e21ad2c1b28ebed975e0ca9615065a4ec98 /include/sfx2
parent8087f479b373299d45469ff3996dba793a9cdb28 (diff)
cool#9992 lok doc sign: add SfxObjectShell::AfterSignContent()
Currently SfxObjectShell::CheckIsReadonly() has a hack for the LOK case to show the signatures dialog read-only, as only that is async. The first problem for the read-write signatures dialog is that SfxObjectShell::ExecFile_Impl() has code after invoking SfxObjectShell::SignDocumentContent(), which will be executed too early if the dialog is executed async. Fix the problem by moving the code in question into a new SfxObjectShell::AfterSignContent(), and only invoke that as a callback after the async run finished. The message dialog in the moved code is still non-async, but we can deal with that later. Change-Id: I32f0895118ac0da72105ec3a24c0294e18c05545 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172914 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
Diffstat (limited to 'include/sfx2')
-rw-r--r--include/sfx2/objsh.hxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/sfx2/objsh.hxx b/include/sfx2/objsh.hxx
index d0cd3e03dd01..ef1c0a5ce992 100644
--- a/include/sfx2/objsh.hxx
+++ b/include/sfx2/objsh.hxx
@@ -361,7 +361,8 @@ public:
void AfterSigning(bool bSignSuccess, bool bSignScriptingContent);
bool HasValidSignatures() const;
SignatureState GetDocumentSignatureState();
- bool SignDocumentContent(weld::Window* pDialogParent);
+ void SignDocumentContent(weld::Window* pDialogParent, const std::function<void(bool)>& rCallback);
+ void AfterSignContent(bool bHaveWeSigned, weld::Window* pDialogParent);
css::uno::Sequence<css::security::DocumentSignatureInformation> GetDocumentSignatureInformation(
bool bScriptingContent,
const css::uno::Reference<css::security::XDocumentDigitalSignatures>& xSigner