diff options
author | Markus Mohrhard <markus.mohrhard@googlemail.com> | 2017-06-28 02:15:04 +0200 |
---|---|---|
committer | Markus Mohrhard <markus.mohrhard@googlemail.com> | 2017-06-28 04:31:34 +0200 |
commit | 669c12d59b6131f44945f166c77ae98df52ebb9e (patch) | |
tree | 9d070a3127f9690d3f51f3f52e515930b2b8c0c4 | |
parent | 9f3814af7264ce90685a82cbf4eb015a38f22bf7 (diff) |
handle SID_ENCRYPTIONDATA for shared password protected docs, tdf#56173
Change-Id: Iadfe880b7be3186410a08568844d8812f176005d
Reviewed-on: https://gerrit.libreoffice.org/39332
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
-rw-r--r-- | sc/source/ui/docshell/docsh4.cxx | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/sc/source/ui/docshell/docsh4.cxx b/sc/source/ui/docshell/docsh4.cxx index 513fc1467eb8..0723f4e06927 100644 --- a/sc/source/ui/docshell/docsh4.cxx +++ b/sc/source/ui/docshell/docsh4.cxx @@ -2439,6 +2439,13 @@ uno::Reference< frame::XModel > ScDocShell::LoadSharedDocument() aArgs[1].Name = "Password"; aArgs[1].Value <<= pPasswordItem->GetValue(); } + const SfxUnoAnyItem* pEncryptionItem = SfxItemSet::GetItem<SfxUnoAnyItem>(GetMedium()->GetItemSet(), SID_ENCRYPTIONDATA, false); + if (pEncryptionItem) + { + aArgs.realloc(aArgs.getLength() + 1); + aArgs[aArgs.getLength() - 1].Name = "EncryptionData"; + aArgs[aArgs.getLength() - 1].Value = pEncryptionItem->GetValue(); + } } xModel.set( |