on xenial help sign in
Made the blinking-animation of the arrows more compact.
436b607Mirco Müller
qml/Notifications/SwipeToAct.qml+13−28
@@ -28,6 +28,7 @@ Item {
28
28
29 property string leftIconName
29 property string leftIconName
30 property string rightIconName
30 property string rightIconName
31+ property double opacityDelta
31 readonly property double sliderHeight: units.gu(8)
32 readonly property double sliderHeight: units.gu(8)
32 readonly property double gap: units.gu(1)
33 readonly property double gap: units.gu(1)
33 readonly property color sliderMainColor: "#b2b2b2"
34 readonly property color sliderMainColor: "#b2b2b2"
@@ -53,6 +54,14 @@ Item {
53 return Qt.rgba(r,g,b,a)
54 return Qt.rgba(r,g,b,a)
54 }
55 }
55
56
57+ UbuntuNumberAnimation on opacityDelta {
58+ from: 0
59+ to: .5
60+ loops: Animation.Infinite
61+ duration: UbuntuAnimation.SleepyDuration
62+ easing.type: Easing.Linear
63+ }
64+
56 UbuntuShape {
65 UbuntuShape {
57 id: row
66 id: row
58 width: parent.width
67 width: parent.width
@@ -97,25 +106,13 @@ Item {
97 name: "back"
106 name: "back"
98 height: units.gu(2.5)
107 height: units.gu(2.5)
99 color: sliderMainColor
108 color: sliderMainColor
100− UbuntuNumberAnimation on opacity {
109+ opacity: .5 + opacityDelta
101− from: .5
102− to: 1
103− loops: Animation.Infinite
104− duration: UbuntuAnimation.SleepyDuration
105− easing.type: Easing.Linear
106− }
107 }
110 }
108 Icon {
111 Icon {
109 name: "back"
112 name: "back"
110 height: units.gu(2.5)
113 height: units.gu(2.5)
111 color: sliderMainColor
114 color: sliderMainColor
112− UbuntuNumberAnimation on opacity {
115+ opacity: 1 - opacityDelta
113− from: 1
114− to: .5
115− loops: Animation.Infinite
116− duration: UbuntuAnimation.SleepyDuration
117− easing.type: Easing.Linear
118− }
119 }
116 }
120 }
117 }
121
118
@@ -179,25 +176,13 @@ Item {
179 name: "next"
176 name: "next"
180 height: units.gu(2.5)
177 height: units.gu(2.5)
181 color: sliderMainColor
178 color: sliderMainColor
182− UbuntuNumberAnimation on opacity {
179+ opacity: 1 - opacityDelta
183− from: 1
184− to: .5
185− loops: Animation.Infinite
186− duration: UbuntuAnimation.SleepyDuration
187− easing.type: Easing.Linear
188− }
189 }
180 }
190 Icon {
181 Icon {
191 name: "next"
182 name: "next"
192 height: units.gu(2.5)
183 height: units.gu(2.5)
193 color: sliderMainColor
184 color: sliderMainColor
194− UbuntuNumberAnimation on opacity {
185+ opacity: 0.5 + opacityDelta
195− from: .5
196− to: 1
197− loops: Animation.Infinite
198− duration: UbuntuAnimation.SleepyDuration
199− easing.type: Easing.Linear
200− }
201 }
186 }
202 }
187 }
203
188