build script, move qml and scripts to src

This commit is contained in:
Robin Appelman
2018-04-02 17:26:32 +02:00
parent 7376aa4e80
commit 8eceaa5294
51 changed files with 57 additions and 738 deletions
+31
View File
@@ -0,0 +1,31 @@
import QtQuick 2.7
import QtQuick.Controls 2.0
import "." // QTBUG-34418, singletons require explicit import to load qmldir file
Button {
property bool activationSoundEnabled: true
hoverEnabled: true
contentItem: MyText {
horizontalAlignment: Text.AlignHCenter
verticalAlignment: Text.AlignVCenter
text: parent.text
color: parent.enabled ? "#ffffff" : "#909090"
}
background: Rectangle {
color: parent.down ? "#406288" : (parent.activeFocus ? "#365473" : "#2c435d")
}
onHoveredChanged: {
if (hovered) {
forceActiveFocus()
} else {
focus = false
}
}
onClicked: {
if (activationSoundEnabled) {
MyResources.playActivationSound()
}
}
}