import QtQuick 2.0
Item {
id: root
width: 800
height: 800
Rectangle {
id: im2
width: 600
height: 50
anchors.centerIn: parent
Rectangle {
id: im1
property int vi: 0
width: 80; height: 80; radius: width/2
anchors.verticalCenter: parent.verticalCenter
x: im2.width*vi/10
PropertyAnimation on vi {
from: 0
to: 10
duration: 3000
loops: Animation.Infinite
running: true
}
}
}
}
import QtQuick 2.0
Item {
id: root
width: 800
height: 800
Rectangle {
id: im2
width: 600
height: 50
anchors.centerIn: parent
Rectangle {
id: im1
property int vi: 0
width: 80; height: 80; radius: width/2
anchors.verticalCenter: parent.verticalCenter
x: im2.width*vi/10
PropertyAnimation on vi {
from: 0
to: 10
duration: 3000
loops: Animation.Infinite
running: true
}
}
}
}
To copy to clipboard, switch view to plain text mode
Bookmarks