Commit 2eb0c67b authored by Marco Martin's avatar Marco Martin Committed by Vlad Zahorodnii
Browse files

Fix dragging especially by touch

The drag manager of a window now can take over from anything, so that
the events to initiate a drag are not stolen by the tap handlers
(fixes the drag starts only the second time is tried issue)

On wayland drag by touch was completely broken by the supportsclosewindows check,
now the touch drag handler is always active and the check of the property is done only
when the drag is over


(cherry picked from commit c1a536a5)
parent 4531e6c0
Pipeline #193221 passed with stage
in 16 minutes and 41 seconds
......@@ -398,7 +398,7 @@ FocusScope {
component DragManager : DragHandler {
id: dragHandler
target: null
grabPermissions: PointerHandler.CanTakeOverFromHandlersOfSameType
grabPermissions: PointerHandler.CanTakeOverFromAnything
readonly property double targetScale: {
if (!heap.supportsDragUpGesture) {
......@@ -433,7 +433,6 @@ FocusScope {
DragManager {
id: touchDragHandler
acceptedDevices: PointerDevice.TouchScreen
enabled: heap.supportsCloseWindows
readonly property double targetOpacity: {
if (!heap.supportsCloseWindows) {
return 1;
......@@ -444,11 +443,8 @@ FocusScope {
onActiveChanged: {
if (!heap.supportsCloseWindows) {
if (!active) {
if (targetOpacity < 0.4) {
if (heap.supportsCloseWindows && targetOpacity < 0.4) {
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment