summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorMichael Stahl <Michael.Stahl@cib.de>2020-03-26 15:24:37 +0100
committerMichael Stahl <Michael.Stahl@cib.de>2020-03-26 17:04:20 +0100
commitb8a807868cae690e6abd19a8eb0e74daf4bdc548 (patch)
tree2cdba99303c5435e94da3c7dc65bfb9d41c094ef /sw
parentc322064eac9a7d562f1a4501df7bb1ddd3ab843f (diff)
sw: PROTECT_FIELDS should not protect placeholder fields
The text placeholder field becomes totally nonfunctional, the other placeholder fields allow inserting but are then not deleted; just ignore protection for placeholder fields. Change-Id: Ic478a32d616464bfe7f24fc851c1998b5e01a23b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91140 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@cib.de> (cherry picked from commit 3fc68fdc6f4ef04091db2fd46499a10396c3a4f2)
Diffstat (limited to 'sw')
-rw-r--r--sw/source/core/crsr/pam.cxx4
1 files changed, 3 insertions, 1 deletions
diff --git a/sw/source/core/crsr/pam.cxx b/sw/source/core/crsr/pam.cxx
index f0d88a26a4d5..8c9ac028bb8b 100644
--- a/sw/source/core/crsr/pam.cxx
+++ b/sw/source/core/crsr/pam.cxx
@@ -751,7 +751,9 @@ bool SwPaM::HasReadonlySel( bool bFormView ) const
{
break; // after selection
}
- if (pHint->Which() == RES_TXTATR_FIELD)
+ if (pHint->Which() == RES_TXTATR_FIELD
+ // placeholders don't work if you can't delete them
+ && pHint->GetFormatField().GetField()->GetTyp()->Which() != SwFieldIds::JumpEdit)
{
return true;
}