1
0
mirror of https://gitlab.com/kelteseth/ScreenPlay.git synced 2024-11-07 03:22:33 +01:00

Change to more consistent animations across SP

This commit is contained in:
Elias 2018-12-15 21:32:49 +01:00
parent c22dcbd982
commit 598a6bec35

View File

@ -12,28 +12,27 @@ Item {
width: parent.width width: parent.width
Rectangle { Rectangle {
id:radiusWorkaround id: radiusWorkaround
height:5 height: 5
radius: 4 radius: 4
color: settingsHeader.background color: settingsHeader.background
anchors{ anchors {
top:parent.top top: parent.top
right: parent.right right: parent.right
left:parent.left left: parent.left
} }
} }
Rectangle { Rectangle {
color: settingsHeader.background color: settingsHeader.background
height:47 height: 47
anchors{ anchors {
top:radiusWorkaround.bottom top: radiusWorkaround.bottom
topMargin: -2 topMargin: -2
right: parent.right right: parent.right
left:parent.left left: parent.left
} }
Item { Item {
anchors { anchors {
fill: parent fill: parent
@ -41,26 +40,24 @@ Item {
leftMargin: 20 leftMargin: 20
} }
Image { Image {
id: imgIcon id: imgIcon
source: settingsHeader.image source: settingsHeader.image
height: 20 height: 20
width: 20 width: 20
sourceSize: Qt.size(20, 20) sourceSize: Qt.size(20, 20)
anchors{ anchors {
top:parent.top top: parent.top
topMargin: 3 topMargin: 3
left:parent.left left: parent.left
leftMargin: 0 leftMargin: 0
} }
} }
ColorOverlay { ColorOverlay {
id:iconColorOverlay id: iconColorOverlay
anchors.fill: imgIcon anchors.fill: imgIcon
source: imgIcon source: imgIcon
color: "#ffffff" color: "#ffffff"
} }
Text { Text {
id: txtHeadline id: txtHeadline
@ -70,10 +67,10 @@ Item {
verticalAlignment: Text.AlignTop verticalAlignment: Text.AlignTop
renderType: Text.NativeRendering renderType: Text.NativeRendering
font.family: "Roboto" font.family: "Roboto"
anchors{ anchors {
top:parent.top top: parent.top
topMargin: 0 topMargin: 0
left:parent.left left: parent.left
leftMargin: 30 leftMargin: 30
} }
} }
@ -117,10 +114,10 @@ Item {
reversible: true reversible: true
NumberAnimation { NumberAnimation {
targets: [imgIcon,txtHeadline] targets: [imgIcon, txtHeadline]
properties: "opacity, anchors.topMargin, anchors.leftMargin" properties: "opacity, anchors.topMargin, anchors.leftMargin"
duration: 300 duration: 400
easing.type: Easing.OutQuart easing.type: Easing.InOutQuart
} }
} }
] ]