[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.4' - desktop/source

Mert Tumer (via logerrit) logerrit at kemper.freedesktop.org
Fri Nov 27 14:32:31 UTC 2020


 desktop/source/lib/init.cxx |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 455cd8fe00d1c756da1bb50a50bac68a1ad645ef
Author:     Mert Tumer <mert.tumer at collabora.com>
AuthorDate: Fri Nov 27 16:56:53 2020 +0300
Commit:     Mert Tumer <mert.tumer at collabora.com>
CommitDate: Fri Nov 27 15:31:59 2020 +0100

    Fix unmodified pdf does forced-save
    
    This is a problem when dealing with the large
    pdfs which take long amount of time to save.
    Adding or removing annotations do change the state of
    IsModified()
    
    Change-Id: I872cb3aec5188986cc13c6659e1bb741a6870409
    Signed-off-by: Mert Tumer <mert.tumer at collabora.com>
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106778
    Reviewed-by: Michael Meeks <michael.meeks at collabora.com>
    Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>

diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index b37c85ffbc63..c9d5e7d1d489 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -3841,7 +3841,7 @@ static void doc_postUnoCommand(LibreOfficeKitDocument* pThis, const char* pComma
     {
         // Check if saving a PDF file
         OUString aMimeType = lcl_getCurrentDocumentMimeType(pDocument);
-        if (aMimeType == "application/pdf")
+        if (pDocSh->IsModified() && aMimeType == "application/pdf")
         {
             // If we have a PDF file (for saving annotations for example), we need
             // to run save-as to the same file as the opened document. Plain save


More information about the Libreoffice-commits mailing list