diff options
author | Szymon Kłos <szymon.klos@collabora.com> | 2019-11-14 11:16:04 +0100 |
---|---|---|
committer | Szymon Kłos <szymon.klos@collabora.com> | 2019-11-14 21:36:05 +0100 |
commit | 77cc0e929ee331af6b97b65e9b6ec5400ef05cd4 (patch) | |
tree | f941d0f616e548042e06fc3814abe47e64072ca3 | |
parent | 2c354558454e66c158c71164eaf56ad18433291c (diff) |
Change-Id: Idbb3e70c1a09be7dd7c43747250f3a6368251cd9
Reviewed-on: https://gerrit.libreoffice.org/82662
Tested-by: Jenkins
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
-rw-r--r-- | sw/source/uibase/shells/drwtxtex.cxx | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/sw/source/uibase/shells/drwtxtex.cxx b/sw/source/uibase/shells/drwtxtex.cxx index 05f9125c6ec1..ae7af539ad73 100644 --- a/sw/source/uibase/shells/drwtxtex.cxx +++ b/sw/source/uibase/shells/drwtxtex.cxx @@ -653,16 +653,19 @@ void SwDrawTextShell::Execute( SfxRequest &rReq ) return; } - std::unique_ptr<SfxItemSet> pNewArgs = pNewAttrs->Clone(); - lcl_convertStringArguments(nSlot, pNewArgs); - - if(nEEWhich && pNewAttrs) + std::unique_ptr<SfxItemSet> pNewArgs = pNewAttrs ? pNewAttrs->Clone() : nullptr; + if (pNewArgs) { - std::unique_ptr<SfxPoolItem> pNewItem(pNewArgs->Get(nWhich).CloneSetWhich(nEEWhich)); - pNewArgs->Put(*pNewItem); - } + lcl_convertStringArguments(nSlot, pNewArgs); + + if (nEEWhich) + { + std::unique_ptr<SfxPoolItem> pNewItem(pNewArgs->Get(nWhich).CloneSetWhich(nEEWhich)); + pNewArgs->Put(*pNewItem); + } - SetAttrToMarked(*pNewArgs); + SetAttrToMarked(*pNewArgs); + } GetView().GetViewFrame()->GetBindings().InvalidateAll(false); |