Juicy Squash - Match-3 Game
import Felgo 4.0
import QtQuick 2.0
Item {
id: splashScreen
z: 1000
property int duration: 4000
signal splashScreenFinished()
Rectangle {
id: splashImage
anchors.fill: parent
gradient: Gradient {
GradientStop { position: 0.0; color: "#142A3C" }
GradientStop { position: 1.0; color: "#080F16" }
}
Column {
id: splashColumn
anchors.centerIn: parent
spacing: 10
Image {
fillMode: Image.PreserveAspectFit
width: splashScreen.width * 0.1
source: Qt.resolvedUrl("../../assets/img/felgo-logo-w256.png")
anchors.horizontalCenter: parent.horizontalCenter
}
Text {
color: "white"
text: "Powered by Felgo"
font.pixelSize: splashScreen.height*0.02
anchors.horizontalCenter: parent.horizontalCenter
}
Text {
color: "white"
text: "www.felgo.com"
font.pixelSize: splashScreen.height*0.0185
anchors.horizontalCenter: parent.horizontalCenter
}
}
MouseArea {
anchors.fill: parent
enabled: !system.publishBuild && splashImage.visible
onClicked: {
NativeUtils.openUrl("https://felgo.com")
}
}
visible: true
z: 1
Timer {
interval: splashScreen.duration
running: true
onTriggered: {
splashImage.opacity = 0
}
}
Behavior on opacity {
NumberAnimation {
duration: 300
}
}
onOpacityChanged: {
if(opacity === 0) {
splashScreen.splashScreenFinished()
splashImage.visible = false
}
}