summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Hung <marklh9@gmail.com>2018-06-18 09:29:05 +0800
committerMark Hung <marklh9@gmail.com>2018-06-24 03:52:41 +0200
commit2862e598d87214aefd8a12d7d083c3fc8da11b57 (patch)
treec52c4bdef71ca5abb8b63ae3f246cddeafa3e26f
parent5c5cced0fcdac73031e5c75ba8e5593be594890c (diff)
tdf#67611 re-add the effect if nothing is left in the textgroup.
Unlike regular shape object whose shape effect were kept after change text grouping to "as object", the effects of all the outline objects were removed. Re-add the effect if nothing is left there. Change-Id: I6d06fad709639f2d2976f6027b8d193f66893c90 Reviewed-on: https://gerrit.libreoffice.org/55973 Tested-by: Jenkins Reviewed-by: Mark Hung <marklh9@gmail.com>
-rw-r--r--sd/source/ui/animations/CustomAnimationPane.cxx11
1 files changed, 11 insertions, 0 deletions
diff --git a/sd/source/ui/animations/CustomAnimationPane.cxx b/sd/source/ui/animations/CustomAnimationPane.cxx
index 497868945385..43f2c119019b 100644
--- a/sd/source/ui/animations/CustomAnimationPane.cxx
+++ b/sd/source/ui/animations/CustomAnimationPane.cxx
@@ -1612,6 +1612,17 @@ void CustomAnimationPane::changeSelection( STLPropertySet const * pResultSet, ST
if( pTextGroup.get() && pTextGroup->getTextGrouping() != nTextGrouping )
{
pEffectSequence->setTextGrouping( pTextGroup, nTextGrouping );
+
+ // All the effects of the outline object is removed so we need to
+ // put it back. OTOH, the shape object that still has effects
+ // in the text group is fine.
+ if (nTextGrouping == -1 && pTextGroup->getEffects().size() == 0)
+ {
+ pEffect->setTarget(makeAny(pEffect->getTargetShape()));
+ pEffect->setGroupId(-1);
+ mpMainSequence->append(pEffect);
+ }
+
bChanged = true;
}
}