include/sfx2/sidebar/DeckTitleBar.hxx | 1 + sfx2/source/sidebar/DeckTitleBar.cxx | 15 +++++++++++++++ 2 files changed, 16 insertions(+)
New commits: commit 16180641a5e0b7a990ec10bbf92e3639b5ee2ee2 Author: Katarina Behrens <[email protected]> Date: Tue Mar 20 12:05:25 2018 +0100 Change mouse cursor to Move when over sidebar deck grip Change-Id: Ic6a271245a6c2da307238d799dbd606e435f7aa1 Reviewed-on: https://gerrit.libreoffice.org/53379 Tested-by: Jenkins <[email protected]> Reviewed-by: Katarina Behrens <[email protected]> diff --git a/include/sfx2/sidebar/DeckTitleBar.hxx b/include/sfx2/sidebar/DeckTitleBar.hxx index 59f15bf1ef93..73daefb4d8e4 100644 --- a/include/sfx2/sidebar/DeckTitleBar.hxx +++ b/include/sfx2/sidebar/DeckTitleBar.hxx @@ -34,6 +34,7 @@ public: tools::Rectangle GetDragArea() const; virtual void DataChanged(const DataChangedEvent& rEvent) override; + virtual void MouseMove(const MouseEvent& rMouseEvent) override; protected: virtual tools::Rectangle GetTitleArea(const tools::Rectangle& rTitleBarBox) override; diff --git a/sfx2/source/sidebar/DeckTitleBar.cxx b/sfx2/source/sidebar/DeckTitleBar.cxx index 891efe8b031c..40450ddeaa7b 100644 --- a/sfx2/source/sidebar/DeckTitleBar.cxx +++ b/sfx2/source/sidebar/DeckTitleBar.cxx @@ -125,6 +125,21 @@ void DeckTitleBar::DataChanged (const DataChangedEvent& rEvent) TitleBar::DataChanged(rEvent); } + +void DeckTitleBar::MouseMove (const MouseEvent& rMouseEvent) +{ + tools::Rectangle aGrip = GetDragArea(); + PointerStyle eStyle = PointerStyle::Arrow; + + if ( aGrip.IsInside( rMouseEvent.GetPosPixel() ) ) + eStyle = PointerStyle::Move; + + Pointer aPtr( eStyle ); + SetPointer( aPtr ); + + Window::MouseMove( rMouseEvent ); +} + } } // end of namespace sfx2::sidebar /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ _______________________________________________ Libreoffice-commits mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
