主要用到AnimatedImage控件即可
import QtQuick 2.5
import QtQuick.Window 2.2
Window {
visible: true
width: 640
height: 480
title: qsTr("Hello World")
MouseArea {
anchors.fill: parent
onClicked: {
Qt.quit();
}
}
AnimatedImage {
anchors.fill: parent
source: "qrc:/braking_animation.gif"
}
Text {
text: qsTr("Hello World")
anchors.centerIn: parent
}
}