[vlc-commits] [Git][videolan/vlc][master] Revert "qml: prevent delivering input events to items outside the viewport in views"
Felix Paul Kühne (@fkuehne)
gitlab at videolan.org
Wed Jun 17 15:58:51 UTC 2026
Felix Paul Kühne pushed to branch master at VideoLAN / VLC
Commits:
323fbdb0 by Fatih Uzunoglu at 2026-06-17T17:46:47+02:00
Revert "qml: prevent delivering input events to items outside the viewport in views"
Sadly this patch is not applicable because `QQuickItem::clip` uses the same flag to
manage clipping. Setting the flag also sets the `clip` property, where we only wanted
to have it to prevent delivering input events outside the view.
I am sorry about this, I will investigate more if there could be an alternative.
This reverts commit 80d7c0aa8e86c0193b7048836d1aacdfd44f8896.
- - - - -
2 changed files:
- modules/gui/qt/widgets/qml/ExpandGridView.qml
- modules/gui/qt/widgets/qml/ListViewExt.qml
Changes:
=====================================
modules/gui/qt/widgets/qml/ExpandGridView.qml
=====================================
@@ -180,24 +180,11 @@ FocusScope {
activeFocusOnTab: true
- function _useClipRectForEventDeliveryWorkaround() {
- if (!root.clip) {
- // The following flag makes sure that the event delivery agent
- // does not deliver the input events to the children of the
- // content item that are outside of the viewport, without
- // clipping the content with a clip node:
- MainCtx.setItemFlag(root, Item.ItemClipsChildrenToShape)
- }
- }
-
// Events
Component.onCompleted: {
if (_initialize())
flickable.layout(true)
-
- clipChanged.connect(root, root._useClipRectForEventDeliveryWorkaround)
- root._useClipRectForEventDeliveryWorkaround()
}
// view needs to be relayout, since items may move
=====================================
modules/gui/qt/widgets/qml/ListViewExt.qml
=====================================
@@ -350,16 +350,6 @@ ListView {
removeDisplaced: moveDisplaced
- function _useClipRectForEventDeliveryWorkaround() {
- if (!root.clip) {
- // The following flag makes sure that the event delivery agent
- // does not deliver the input events to the children of the
- // content item that are outside of the viewport, without
- // clipping the content with a clip node:
- MainCtx.setItemFlag(root, Item.ItemClipsChildrenToShape)
- }
- }
-
// Events
Component.onCompleted: {
@@ -368,9 +358,6 @@ ListView {
// feature for non-touch cases, so disable it here and enable
// it if touch is detected through the hover handler:
MainCtx.setFiltersChildMouseEvents(root, false)
-
- clipChanged.connect(root, root._useClipRectForEventDeliveryWorkaround)
- root._useClipRectForEventDeliveryWorkaround()
}
HoverHandler {
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/323fbdb0521d9e7f105382d4ddaf91d05d84a7b7
--
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/323fbdb0521d9e7f105382d4ddaf91d05d84a7b7
You're receiving this email because of your account on code.videolan.org. Manage all notifications: https://code.videolan.org/-/profile/notifications | Help: https://code.videolan.org/help
More information about the vlc-commits
mailing list