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 /include/vcl/toolbox.hxx | |
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 'include/vcl/toolbox.hxx')
-rw-r--r-- | include/vcl/toolbox.hxx | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/include/vcl/toolbox.hxx b/include/vcl/toolbox.hxx index e0b4fd731fde..12a0b7029f9b 100644 --- a/include/vcl/toolbox.hxx +++ b/include/vcl/toolbox.hxx @@ -20,13 +20,16 @@ #ifndef INCLUDED_VCL_TOOLBOX_HXX #define INCLUDED_VCL_TOOLBOX_HXX -#include <com/sun/star/frame/XFrame.hpp> +#include <vcl/vclstatuslistener.hxx> #include <rsc/rsc-vcl-shared-types.hxx> #include <vcl/dllapi.h> #include <vcl/dockwin.hxx> #include <vcl/image.hxx> #include <vector> +#include <com/sun/star/frame/XFrame.hpp> +#include <com/sun/star/frame/FeatureStateEvent.hpp> + class Timer; class UserDrawEvent; struct ImplToolItem; @@ -94,6 +97,7 @@ private: long mnBottomBorder; long mnLastResizeDY; long mnActivateCount; + long mnImagesRotationAngle; sal_uInt16 mnLastFocusItemId; sal_uInt16 mnFocusPos; sal_uInt16 mnOutStyle; @@ -128,7 +132,8 @@ private: mbMenuStrings:1, mbIsShift:1, mbIsKeyEvent:1, - mbChangingHighlight:1; + mbChangingHighlight:1, + mbImagesMirrored:1; WindowAlign meAlign; WindowAlign meDockAlign; ButtonType meButtonType; @@ -143,6 +148,8 @@ private: Link<CommandEvent const *, void> maCommandHandler; Link<StateChangedType const *, void> maStateChangedHandler; Link<DataChangedEvent const *, void> maDataChangedHandler; + /** StatusListener. Notifies about rotated images etc */ + rtl::Reference<VclStatusListener<ToolBox>> mpStatusListener; public: using Window::ImplInit; @@ -356,6 +363,7 @@ public: void SetItemImage( sal_uInt16 nItemId, const Image& rImage ); Image GetItemImage( sal_uInt16 nItemId ) const; Image GetItemImageOriginal( sal_uInt16 nItemId ) const; + void UpdateImageOrientation(); void SetItemImageAngle( sal_uInt16 nItemId, long nAngle10 ); void SetItemImageMirrorMode( sal_uInt16 nItemId, bool bMirror ); void SetItemText( sal_uInt16 nItemId, const OUString& rText ); @@ -499,6 +507,7 @@ public: void ChangeHighlight( sal_uInt16 nPos ); void SetToolbarLayoutMode( ToolBoxLayoutMode eLayout ); + void statusChanged(const css::frame::FeatureStateEvent& rEvent); }; inline void ToolBox::CheckItem( sal_uInt16 nItemId, bool bCheck ) |