diff options
author | Povilas Kanapickas <povilas@radix.lt> | 2022-09-02 00:04:42 +0300 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2022-09-05 16:22:31 +0200 |
commit | d752cb42473547872741c74a70809f28f9fe789c (patch) | |
tree | b967cd9446feec9cadb57c408b825a6dab14945c /vcl/source/window/winproc.cxx | |
parent | 35319adcc28f197b73e146f9ba233e20616fd11f (diff) |
vcl: Rename LongPress event to GestureLongPress
We have 5 gesture types: GestureZoom, GestureRotate, GesturePan,
GestureSwipe and LongPress. For consistency all of these will use
Gesture as a prefix to reduce confusion and for easier grepping
throughout the codebase.
Change-Id: I8b9e245d011203a19c1172f9833c172f65382cab
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139244
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'vcl/source/window/winproc.cxx')
-rw-r--r-- | vcl/source/window/winproc.cxx | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/vcl/source/window/winproc.cxx b/vcl/source/window/winproc.cxx index e0af8255e514..45182d0a09f8 100644 --- a/vcl/source/window/winproc.cxx +++ b/vcl/source/window/winproc.cxx @@ -1769,27 +1769,27 @@ static bool ImplHandleSwipe(vcl::Window *pWindow, const SalGestureSwipeEvent& rE namespace { -class HandleLongPressEvent : public HandleGestureEvent +class HandleGestureLongPressEvent : public HandleGestureEvent { private: - CommandLongPressData m_aLongPressData; + CommandGestureLongPressData m_aLongPressData; public: - HandleLongPressEvent(vcl::Window *pWindow, const SalLongPressEvent& rEvt) + HandleGestureLongPressEvent(vcl::Window *pWindow, const SalGestureLongPressEvent& rEvt) : HandleGestureEvent(pWindow, Point(rEvt.mnX, rEvt.mnY)), m_aLongPressData(rEvt.mnX, rEvt.mnY) { } virtual bool CallCommand(vcl::Window *pWindow, const Point &/*rMousePos*/) override { - return ImplCallCommand(pWindow, CommandEventId::LongPress, &m_aLongPressData); + return ImplCallCommand(pWindow, CommandEventId::GestureLongPress, &m_aLongPressData); } }; } -static bool ImplHandleLongPress(vcl::Window *pWindow, const SalLongPressEvent& rEvt) +static bool ImplHandleLongPress(vcl::Window *pWindow, const SalGestureLongPressEvent& rEvt) { - HandleLongPressEvent aHandler(pWindow, rEvt); + HandleGestureLongPressEvent aHandler(pWindow, rEvt); return aHandler.HandleEvent(); } @@ -2907,8 +2907,8 @@ bool ImplWindowFrameProc( vcl::Window* _pWindow, SalEvent nEvent, const void* pE bRet = ImplHandleSwipe(pWindow, *static_cast<const SalGestureSwipeEvent*>(pEvent)); break; - case SalEvent::LongPress: - bRet = ImplHandleLongPress(pWindow, *static_cast<const SalLongPressEvent*>(pEvent)); + case SalEvent::GestureLongPress: + bRet = ImplHandleLongPress(pWindow, *static_cast<const SalGestureLongPressEvent*>(pEvent)); break; case SalEvent::ExternalGesture: |