[vlc-commits] [Git][videolan/vlc][master] 4 commits: qml: accept all devices in Flickable tap handlers
Felix Paul Kühne (@fkuehne)
gitlab at videolan.org
Mon Oct 28 05:59:56 UTC 2024
Felix Paul Kühne pushed to branch master at VideoLAN / VLC
Commits:
f4c79a85 by Fatih Uzunoglu at 2024-10-28T05:32:43+00:00
qml: accept all devices in Flickable tap handlers
Setting the accepted device to only mouse causes
problems. Sometimes, particularly on Wayland,
mouse does not identify as a mouse. At the same
time, track pad can not be used as well as it is
considered to be a different device (and not allowed
here).
This was used to prevent interfering with dragging
and flicking the view, which is a use case mainly
with touch screen. However, according to QTBUG-73035,
and commit 250053 [1], it appears that having a direct
tap handler within Flickable should not cause issues
with touch screen.
[1] https://codereview.qt-project.org/c/qt/qtdeclarative/+/250053
- - - - -
37a5e145 by Fatih Uzunoglu at 2024-10-28T05:32:43+00:00
qml: disable dragging item view delegates with touch screen
It is not possible to have both delegate dragging and Flickable
dragging/flicking. Since scrolling the view is more important
than dragging the delegate, the drag handler of the delegate
should not accept touch screen so that the Flickable can handle
dragging and flicking for scrolling.
- - - - -
e2939def by Fatih Uzunoglu at 2024-10-28T05:32:43+00:00
qml: do not restrict hover handler to mouse in GridItem
Setting the accepted device to only mouse causes
problems. Sometimes, particularly on Wayland,
mouse does not identify as a mouse. At the same
time, track pad can not be used as well as it is
considered to be a different device (and not allowed
here).
- - - - -
c96d2430 by Fatih Uzunoglu at 2024-10-28T05:32:43+00:00
qml: do not restrict hover handler to mouse in SliderExt
Setting the accepted device to only mouse causes
problems. Sometimes, particularly on Wayland,
mouse does not identify as a mouse. At the same
time, track pad can not be used as well as it is
considered to be a different device (and not allowed
here).
- - - - -
7 changed files:
- modules/gui/qt/medialibrary/qml/MusicArtistDelegate.qml
- modules/gui/qt/playlist/qml/PlaylistDelegate.qml
- modules/gui/qt/widgets/qml/ExpandGridView.qml
- modules/gui/qt/widgets/qml/GridItem.qml
- modules/gui/qt/widgets/qml/ListViewExt.qml
- modules/gui/qt/widgets/qml/SliderExt.qml
- modules/gui/qt/widgets/qml/TableViewDelegate.qml
Changes:
=====================================
modules/gui/qt/medialibrary/qml/MusicArtistDelegate.qml
=====================================
@@ -112,6 +112,8 @@ T.ItemDelegate {
}
DragHandler {
+ acceptedDevices: PointerDevice.AllDevices & ~(PointerDevice.TouchScreen)
+
target: null
grabPermissions: PointerHandler.CanTakeOverFromHandlersOfDifferentType | PointerHandler.ApprovesTakeOverByAnything
=====================================
modules/gui/qt/playlist/qml/PlaylistDelegate.qml
=====================================
@@ -275,6 +275,8 @@ T.Control {
DragHandler {
id: dragHandler
+ acceptedDevices: PointerDevice.AllDevices & ~(PointerDevice.TouchScreen)
+
target: null
grabPermissions: PointerHandler.CanTakeOverFromHandlersOfDifferentType | PointerHandler.ApprovesTakeOverByAnything
=====================================
modules/gui/qt/widgets/qml/ExpandGridView.qml
=====================================
@@ -776,8 +776,6 @@ FocusScope {
}
TapHandler {
- acceptedDevices: PointerDevice.Mouse
-
acceptedButtons: Qt.LeftButton | Qt.RightButton
grabPermissions: PointerHandler.TakeOverForbidden
=====================================
modules/gui/qt/widgets/qml/GridItem.qml
=====================================
@@ -167,6 +167,8 @@ T.ItemDelegate {
DragHandler {
id: dragHandler
+ acceptedDevices: PointerDevice.AllDevices & ~(PointerDevice.TouchScreen)
+
target: null
grabPermissions: PointerHandler.CanTakeOverFromHandlersOfDifferentType | PointerHandler.ApprovesTakeOverByAnything
@@ -372,7 +374,6 @@ T.ItemDelegate {
HoverHandler {
id: subtitleTxtMouseHandler
- acceptedDevices: PointerDevice.Mouse
}
}
}
=====================================
modules/gui/qt/widgets/qml/ListViewExt.qml
=====================================
@@ -536,8 +536,6 @@ ListView {
}
TapHandler {
- acceptedDevices: PointerDevice.Mouse
-
acceptedButtons: Qt.LeftButton | Qt.RightButton
grabPermissions: PointerHandler.TakeOverForbidden
=====================================
modules/gui/qt/widgets/qml/SliderExt.qml
=====================================
@@ -133,8 +133,6 @@ T.Slider {
HoverHandler {
id: hoverHandler
- acceptedPointerTypes: PointerDevice.Mouse
-
enabled: true
target: background
=====================================
modules/gui/qt/widgets/qml/TableViewDelegate.qml
=====================================
@@ -111,6 +111,8 @@ T.Control {
DragHandler {
id: dragHandler
+ acceptedDevices: PointerDevice.AllDevices & ~(PointerDevice.TouchScreen)
+
target: null
grabPermissions: PointerHandler.CanTakeOverFromHandlersOfDifferentType | PointerHandler.ApprovesTakeOverByAnything
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/0450706563e262c5728ff159241ec276fc359969...c96d243056249804938bb35f7bbc5731e97de449
--
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/0450706563e262c5728ff159241ec276fc359969...c96d243056249804938bb35f7bbc5731e97de449
You're receiving this email because of your account on code.videolan.org.
VideoLAN code repository instance
More information about the vlc-commits
mailing list