I’ve now updated my branch to use the public SwipeArea component from the UITK, and I’m still seeing an issue similar to the one originally reported. I can reproduce it with a minimal standalone example:
I instrumented oxide to print a log statement every time a touch event is detected, and when starting a drag even from the bottom edge, the following happens:
It appears the webview is getting a TouchBegin event, followed by a number of TouchUpdate events, before the SwipeArea even detects a drag. When it does, events stop being sent to the webview, which as a consequence never gets a TouchEnd event to match the first TouchBegin event, leaving it in an inconsistent state.
I’ve now updated my branch to use the public SwipeArea component from the UITK, and I’m still seeing an issue similar to the one originally reported. I can reproduce it with a minimal standalone example:
import QtQuick 2.4 /en.wikipedia. org/wiki/ Ubuntu_ (operating_ system)" hanged: console. log("dragging: ", dragging) hanged: console. log("distance: ", distance)
import Ubuntu.Components 1.3
import com.canonical.Oxide 1.11
WebView {
url: "https:/
SwipeArea {
direction: SwipeArea.Upwards
onDraggingC
onDistanceC
anchors {
left: parent.left
right: parent.right
bottom: parent.bottom
}
height: units.gu(2)
}
}
I instrumented oxide to print a log statement every time a touch event is detected, and when starting a drag even from the bottom edge, the following happens:
qml: distance: 0 iew::touchEvent (QTouchEvent* ) QTouchEvent( TouchBegin states: QFlags(0x1), 1 points: (TouchPoint(0 QRectF( 599.979, 1848.5 2.9974x2.9974) pressed))) iew::touchEvent (QTouchEvent* ) QTouchEvent( TouchUpdate states: QFlags(0x2), 1 points: (TouchPoint(0 QRectF( 613.967, 1676.09 2.9974x1.99827) moved))) iew::touchEvent (QTouchEvent* ) QTouchEvent( TouchUpdate states: QFlags(0x2), 1 points: (TouchPoint(0 QRectF( 618.213, 1623.12 4.99566x2.9974) moved))) iew::touchEvent (QTouchEvent* ) QTouchEvent( TouchUpdate states: QFlags(0x2), 1 points: (TouchPoint(0 QRectF( 620.961, 1507.47 2.9974x1.99827) moved))) iew::touchEvent (QTouchEvent* ) QTouchEvent( TouchUpdate states: QFlags(0x2), 1 points: (TouchPoint(0 QRectF( 620.961, 1492.02 2.9974x1.99827) moved)))
virtual void OxideQQuickWebV
virtual void OxideQQuickWebV
virtual void OxideQQuickWebV
virtual void OxideQQuickWebV
virtual void OxideQQuickWebV
qml: dragging: true
qml: distance: 148.6371093749999
[…]
qml: distance: 513.631586442578
qml: dragging: false
It appears the webview is getting a TouchBegin event, followed by a number of TouchUpdate events, before the SwipeArea even detects a drag. When it does, events stop being sent to the webview, which as a consequence never gets a TouchEnd event to match the first TouchBegin event, leaving it in an inconsistent state.