Kaydet (Commit) 5ee141ee authored tarafından Noel Grandin's avatar Noel Grandin

tdf#113935 Switching from read-only to edit mode slow

Regression introduced by

    commit 389da66d
    remove unused uno::Reference vars

I'm guessing this variable keeps some kind of cache alive which prevents
us from re-parsing the PDF file when we switch to edit mode - which is
clearly what we are doing when I remove the line.

Change-Id: Iea2cf9640d876028a78806e717b930d4a063dc9b
Reviewed-on: https://gerrit.libreoffice.org/45093Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarNoel Grandin <noel.grandin@collabora.co.uk>
üst 72ef2b5d
......@@ -383,6 +383,11 @@ void SfxObjectShell::UpdateFromTemplate_Impl( )
// update only for documents loaded from the local file system
return;
// tdf#113935 - do not remove this line - somehow, it makes the process
// of switching from viewing a read-only document to opening it in writable
// mode much faster.
uno::Reference< embed::XStorage > xDocStor = pFile->GetStorage();
// only for own storage formats
if ( !pFile->GetFilter() || !pFile->GetFilter()->IsOwnFormat() )
return;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment