diff options
author | Tomaž Vajngerl <tomaz.vajngerl@collabora.co.uk> | 2019-06-15 15:44:33 +0900 |
---|---|---|
committer | Andras Timar <andras.timar@collabora.com> | 2019-06-17 15:08:37 +0200 |
commit | 74456219dc5c5716c023d69abc7ad6f7d90b4a33 (patch) | |
tree | 61f201bd0627079315c18339c67334b6abf62251 /vcl/source/control/listctrl.cxx | |
parent | 49943f9930e1794063f1e7353d37bc98b79c39e7 (diff) |
tdf#124907 vcl: react to pan gesture for listbox and other widgets
cd-6.0-29
Reviewed-on: https://gerrit.libreoffice.org/74087
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
(cherry picked from commit 08f485c6e92bd56c8c26171316b842cd213a8a09)
Change-Id: I4579f8edd2bf24506b1d55a7291cd86e276f30a4
Reviewed-on: https://gerrit.libreoffice.org/74164
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
Diffstat (limited to 'vcl/source/control/listctrl.cxx')
-rw-r--r-- | vcl/source/control/listctrl.cxx | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/vcl/source/control/listctrl.cxx b/vcl/source/control/listctrl.cxx index 50b03eddc918..62f6a1dbc90a 100644 --- a/vcl/source/control/listctrl.cxx +++ b/vcl/source/control/listctrl.cxx @@ -158,9 +158,15 @@ bool ListControl::EventNotify( NotifyEvent& rNEvt ) if (rNEvt.GetType() == MouseNotifyEvent::COMMAND) { const CommandEvent* pEvent = rNEvt.GetCommandEvent(); - if (pEvent && pEvent->GetCommand() == CommandEventId::Wheel) + if (pEvent) { - HandleScrollCommand(*pEvent, nullptr, mpScrollBar.get()); + CommandEventId nCommand = pEvent->GetCommand(); + + if (nCommand == CommandEventId::Wheel || + nCommand == CommandEventId::Gesture) + { + HandleScrollCommand(*pEvent, nullptr, mpScrollBar.get()); + } } } return true; |