chart2/inc/ChartView.hxx | 8 ++++---- sc/source/ui/view/gridwin.cxx | 27 +++++++++++++++++++++++++++ 2 files changed, 31 insertions(+), 4 deletions(-)
New commits: commit 30d6bf6f25c1531e10454739b791ee572b59b251 Author: Markus Mohrhard <markus.mohrh...@collabora.co.uk> Date: Mon May 12 08:51:51 2014 +0200 volatile does not make any sense here Change-Id: I895f6d04bbd5bd1829ec72b2051e640cbc153b26 diff --git a/chart2/inc/ChartView.hxx b/chart2/inc/ChartView.hxx index bc458a9..0ba3bf8 100644 --- a/chart2/inc/ChartView.hxx +++ b/chart2/inc/ChartView.hxx @@ -252,10 +252,10 @@ private: //member ::cppu::OMultiTypeInterfaceContainerHelper m_aListenerContainer; - bool volatile m_bViewDirty; //states whether the view needs to be rebuild - bool volatile m_bInViewUpdate; - bool volatile m_bViewUpdatePending; - bool volatile m_bRefreshAddIn; + bool m_bViewDirty; //states whether the view needs to be rebuild + bool m_bInViewUpdate; + bool m_bViewUpdatePending; + bool m_bRefreshAddIn; //better performance for big data ::com::sun::star::awt::Size m_aPageResolution; commit a2576b2d43684c54a9270ce93b5a721296faf8da Author: Markus Mohrhard <markus.mohrh...@collabora.co.uk> Date: Mon May 12 08:28:36 2014 +0200 send mouse events to the OpenGL window No idea why the events are send to ScgridWindow but this hack works for now. It is not perfect and surely not beautiful but does work. Change-Id: If620e471083d34004ee877a25f8731d7b4212f3c diff --git a/sc/source/ui/view/gridwin.cxx b/sc/source/ui/view/gridwin.cxx index 2082d8d..95ce9fd 100644 --- a/sc/source/ui/view/gridwin.cxx +++ b/sc/source/ui/view/gridwin.cxx @@ -1636,6 +1636,33 @@ bool ScGridWindow::TestMouse( const MouseEvent& rMEvt, bool bAction ) void ScGridWindow::MouseButtonDown( const MouseEvent& rMEvt ) { + if(!maChildWindows.empty()) + { + const Point& rPos = rMEvt.GetPosPixel(); + for(boost::ptr_vector<Window>::iterator itr = maChildWindows.begin(), + itrEnd = maChildWindows.end(); itr != itrEnd; ++itr) + { + Point aPoint = itr->GetPosPixel(); + Size aSize = itr->GetSizePixel(); + + if(rPos.X() >= aPoint.X() && rPos.X() <= (aPoint.X() + aSize.Width()) + && rPos.Y() >= aPoint.Y() && rPos.Y() <= (aPoint.Y() + aSize.Height())) + { + // we found a mouse event for the child window + // we need to recalculate the position based on the child window + + Point aNewPos = rPos - aPoint; + sal_uInt16 nClicks = rMEvt.GetClicks(); + sal_uInt16 nMode = rMEvt.GetMode(); + sal_uInt16 nButtons = rMEvt.GetButtons(); + sal_uInt16 nModifier = rMEvt.GetModifier(); + + MouseEvent aEvent(aNewPos, nClicks, nMode, nButtons, nModifier); + itr->MouseButtonDown(aEvent); + return; + } + } + } nNestedButtonState = SC_NESTEDBUTTON_DOWN; MouseEventState aState; _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits