Hi,
If I set a MouseArea to fill a Row with Repeater-generated content, is
it possible to know which generated item is currently under mouse cursor?
I'd like to use MouseArea's onPositionChanged-event to do some things
for a Row item when mouse cursor is moving over it. From MouseEvent I
get the cursor xy-coordinates but is there a reasonable way of mapping
them to a Row item?
e.g.
Row {
id: row
Repeater {
model: 5
delegate: Rectangle { width: 50; height: 10 }
}
}
MouseArea {
anchors.fill: row
onPositionChanged: { /* get row item under x,y and do something with
it */ }
}
Or any other way of implementing similar functionality?
This would allow a nice visualization effect e.g. when you show image
thumbnails within a grid. While moving your mouse around the grid, the
thumbnail under cursor would show up as a larger image and then fade
back to thumbnail as the mouse cursor moves forward to the next item.
Br,
matti
_______________________________________________
Qt-qml mailing list
[email protected]
http://lists.qt.nokia.com/mailman/listinfo/qt-qml