summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2020-12-01 09:09:45 +0000
committerAdolfo Jayme Barrientos <fitojb@ubuntu.com>2020-12-02 14:18:08 +0100
commit49f0410cafcc2bd3b417427d3d17de8abb8ea3b4 (patch)
tree38f8cce4e540e993fb47538542edf944de033894 /svx
parent1ad0ec4f10270eb44b558e6e8c6261d793fddb2f (diff)
Resolves: tdf#138549 use GetSpecialTextBoxShadow to identify ScPostIt
instead of a 'special' name which causes undo-related causes side effects Change-Id: Id36b0b5360ddde3469721a7c837fe3942af08209 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106924 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> (cherry picked from commit 9c94bae963ef5019f6ca0394d076b1288969aa53) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107024 Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
Diffstat (limited to 'svx')
-rw-r--r--svx/source/svdraw/svdotxat.cxx7
1 files changed, 5 insertions, 2 deletions
diff --git a/svx/source/svdraw/svdotxat.cxx b/svx/source/svdraw/svdotxat.cxx
index 4b96bb04c12a..5ba5ec6a82cc 100644
--- a/svx/source/svdraw/svdotxat.cxx
+++ b/svx/source/svdraw/svdotxat.cxx
@@ -263,8 +263,12 @@ bool SdrTextObj::AdjustTextFrameWidthAndHeight()
if (auto pRectObj = dynamic_cast<SdrRectObj *>(this)) { // this is a hack
pRectObj->SetXPolyDirty();
}
+ bool bScPostIt = false;
if (auto pCaptionObj = dynamic_cast<SdrCaptionObj *>(this)) { // this is a hack
pCaptionObj->ImpRecalcTail();
+ // tdf#114956, tdf#138549 use GetSpecialTextBoxShadow to recognize
+ // that this SdrCaption is for a ScPostit
+ bScPostIt = pCaptionObj->GetSpecialTextBoxShadow();
}
// to not slow down EditView visualization on Overlay (see
@@ -278,8 +282,7 @@ bool SdrTextObj::AdjustTextFrameWidthAndHeight()
GetTextEditOutliner() &&
GetTextEditOutliner()->hasEditViewCallbacks());
- // tdf#114956 always broadcast change for ScPostIts
- if (!bSuppressChangeWhenEditOnOverlay || GetName() == "ScPostIt")
+ if (!bSuppressChangeWhenEditOnOverlay || bScPostIt)
{
SetChanged();
BroadcastObjectChange();