[Libreoffice-commits] core.git: Branch 'libreoffice-7-1' - sw/source

Michael Stahl (via logerrit) logerrit at kemper.freedesktop.org
Thu Jan 28 10:12:43 UTC 2021


 sw/source/core/crsr/pam.cxx |    8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

New commits:
commit 041ecabb7bf6ad15c2cdcf228cb9dc82b2d16837
Author:     Michael Stahl <michael.stahl at allotropia.de>
AuthorDate: Wed Jan 27 13:21:35 2021 +0100
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Thu Jan 28 11:12:00 2021 +0100

    sw_fieldmarkhide: adjust SwPaM::HasReadonlySel() to the fact that...
    
    ... there is, in fact, an else branch. D'oh.
    
    (regression from f8da730bd66d5d6d3e49935573b3223c06baffbe)
    
    Change-Id: I378b0a78a4ccc9a0e7fa9a6bf2e1ecb456133bed
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110012
    Tested-by: Jenkins
    Reviewed-by: Michael Stahl <michael.stahl at allotropia.de>
    (cherry picked from commit e65376ecd6e4356686927a5daeb845faf1fc4a42)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109985
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/sw/source/core/crsr/pam.cxx b/sw/source/core/crsr/pam.cxx
index 684b6e5eae72..fe3f41a9a76c 100644
--- a/sw/source/core/crsr/pam.cxx
+++ b/sw/source/core/crsr/pam.cxx
@@ -730,9 +730,11 @@ bool SwPaM::HasReadonlySel( bool bFormView ) const
     const bool bAtStartA = (pA != nullptr) && (pA->GetMarkStart() == *GetPoint());
     const bool bAtStartB = (pB != nullptr) && (pB->GetMarkStart() == *GetMark());
 
-    if (!bRet &&
-        // allow editing all fields in generic mode
-        !officecfg::Office::Common::Filter::Microsoft::Import::ForceImportWWFieldsAsGenericFields::get(comphelper::getProcessComponentContext()))
+    if (officecfg::Office::Common::Filter::Microsoft::Import::ForceImportWWFieldsAsGenericFields::get(comphelper::getProcessComponentContext()))
+    {
+        ; // allow editing all fields in generic mode
+    }
+    else if (!bRet)
     {
         bool bUnhandledMark = pA && pA->GetFieldname( ) == ODF_UNHANDLED;
         // Unhandled fieldmarks case shouldn't be edited manually to avoid breaking anything


More information about the Libreoffice-commits mailing list