diff options
author | Szymon Kłos <szymon.klos@collabora.com> | 2019-11-05 10:35:49 +0100 |
---|---|---|
committer | Szymon Kłos <szymon.klos@collabora.com> | 2019-11-05 12:51:46 +0100 |
commit | 8fbb4923d1477ba019478c34e3d370f05844ea47 (patch) | |
tree | 480724edfd025cc46cf7ae307cf93a373bb2e6cb /sd | |
parent | d0691fd2f57c1ed2927b3c3e78d0ce59558eb3a7 (diff) |
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.klos@collabora.com>
(cherry picked from commit 78d81c2e6ee4eb7caf2d4822657bc4eaa57bfc79)
Reviewed-on: https://gerrit.libreoffice.org/82060
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Diffstat (limited to 'sd')
-rw-r--r-- | sd/source/ui/view/drtxtob1.cxx | 22 |
1 files changed, 18 insertions, 4 deletions
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 |