diff options
author | Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> | 2015-12-04 17:05:11 +0100 |
---|---|---|
committer | Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> | 2015-12-08 08:39:44 +0000 |
commit | ac97f32307feb488c86d6fa962258fe79320d31b (patch) | |
tree | baaf15380630c4dbeeea827fb6ab004193bb5ac0 /vcl/source/window/toolbox2.cxx | |
parent | e4d5b5efac71ed2a08dcd09877078a6cf6bde0d2 (diff) |
Move icon rotation/flip handling from ToolbarManager to vcl's Toolbar
This enables rotatad/flipped icons in the Sidebar and other non-toolbar places (tdf#85767)
Change-Id: I034394ae6f9b8d91ef5a376a43eda587098f064e
Reviewed-on: https://gerrit.libreoffice.org/20403
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Diffstat (limited to 'vcl/source/window/toolbox2.cxx')
-rw-r--r-- | vcl/source/window/toolbox2.cxx | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/vcl/source/window/toolbox2.cxx b/vcl/source/window/toolbox2.cxx index 2bcb44ec85b9..74326f8dd5a2 100644 --- a/vcl/source/window/toolbox2.cxx +++ b/vcl/source/window/toolbox2.cxx @@ -1232,6 +1232,17 @@ void ToolBox::SetItemImageMirrorMode( sal_uInt16 nItemId, bool bMirror ) } } +void ToolBox::UpdateImageOrientation() +{ + for (std::vector<ImplToolItem>::const_iterator it = mpData->m_aItems.begin(); it != mpData->m_aItems.end(); ++it) + { + if (vcl::CommandInfoProvider::Instance().IsMirrored(it->maCommandStr)) + SetItemImageMirrorMode(it->mnId, mbImagesMirrored); + if (vcl::CommandInfoProvider::Instance().IsRotated(it->maCommandStr)) + SetItemImageAngle(it->mnId, mnImagesRotationAngle); + } +} + Image ToolBox::GetItemImage(sal_uInt16 nItemId) const { ImplToolItem* pItem = ImplGetItem(nItemId); |