sd/source/ui/view/drtxtob1.cxx | 22 ++++++++++++++++++---- svx/sdi/svx.sdi | 2 +- 2 files changed, 19 insertions(+), 5 deletions(-)
New commits: commit 8fbb4923d1477ba019478c34e3d370f05844ea47 Author: Szymon Kłos <szymon.k...@collabora.com> AuthorDate: Tue Nov 5 10:35:49 2019 +0100 Commit: Szymon Kłos <szymon.k...@collabora.com> CommitDate: Tue Nov 5 12:51:46 2019 +0100 jsdialogs: .uno:ChartBackColor with string argument Change-Id: I2f28a0ba957548b020eacf3d630dccef6ebbf5ed Reviewed-on: https://gerrit.libreoffice.org/82057 Tested-by: Jenkins Reviewed-by: Szymon Kłos <szymon.k...@collabora.com> (cherry picked from commit 78d81c2e6ee4eb7caf2d4822657bc4eaa57bfc79) Reviewed-on: https://gerrit.libreoffice.org/82060 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoff...@gmail.com> diff --git a/sd/source/ui/view/drtxtob1.cxx b/sd/source/ui/view/drtxtob1.cxx index 5d3e109e688c..92926a075393 100644 --- a/sd/source/ui/view/drtxtob1.cxx +++ b/sd/source/ui/view/drtxtob1.cxx @@ -79,7 +79,7 @@ namespace { - void lcl_convertStringArguments(std::unique_ptr<SfxItemSet>& pArgs) + void lcl_convertStringArguments(sal_uInt16 nSlot, std::unique_ptr<SfxItemSet>& pArgs) { Color aColor; OUString sColor; @@ -94,8 +94,22 @@ namespace else aColor = Color(sColor.toInt32(16)); - SvxColorItem aColorItem(aColor, EE_CHAR_COLOR); - pArgs->Put(aColorItem); + switch (nSlot) + { + case SID_ATTR_CHAR_COLOR: + { + SvxColorItem aColorItem(aColor, EE_CHAR_COLOR); + pArgs->Put(aColorItem); + break; + } + + case SID_ATTR_CHAR_BACK_COLOR: + { + SvxBackgroundColorItem pBackgroundItem(aColor, EE_CHAR_BKGCOLOR); + pArgs->Put(pBackgroundItem); + break; + } + } } } } @@ -715,7 +729,7 @@ void TextObjectBar::Execute( SfxRequest &rReq ) } std::unique_ptr<SfxItemSet> pNewArgs = pArgs->Clone(); - lcl_convertStringArguments(pNewArgs); + lcl_convertStringArguments(nSlot, pNewArgs); mpView->SetAttributes(*pNewArgs); // invalidate entire shell because of performance and diff --git a/svx/sdi/svx.sdi b/svx/sdi/svx.sdi index 74e30f53dcfa..2a9794185910 100644 --- a/svx/sdi/svx.sdi +++ b/svx/sdi/svx.sdi @@ -1507,7 +1507,7 @@ SvxColorItem Color SID_ATTR_CHAR_COLOR ] SvxBackgroundColorItem CharBackColor SID_ATTR_CHAR_BACK_COLOR - +(SfxStringItem Color SID_ATTR_COLOR_STR, SvxBackgroundColorItem CharBackColor SID_ATTR_CHAR_BACK_COLOR) [ AutoUpdate = TRUE, FastCall = FALSE, _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits