Quantcast
Channel: Qt DevNet forums: Qt Quick 1283365070**
Viewing all articles
Browse latest Browse all 4972

Handle touch event and flicks simultaneously in Qml

$
0
0
I’m trying to write UI on Qml with two capabilities: 1) handle touch event (to choose some object) 2) handle flick events (to view some large object) It’s my code: Rectangle {     width: 500; height: 500     Flickable {         anchors.fill: parent           onContentXChanged: {         console.log("x changed")         //redraw large object       MouseArea {         anchors.fill: parent         preventStealing: true           onClicked: {         console.log("clicked")         //choose some object         }     } } I have two problems: 1) On Android clicked events don’t appear (even with preventStealing property) 2) How can I differ short touch (clicked) event from pressing+dragging+releasing? As I understand, MouseArea must send clicked event in both cases.

Viewing all articles
Browse latest Browse all 4972

Trending Articles