extract PulseAnimation component from 3 modules
This commit is contained in:
parent
8d76df6ef5
commit
b5be146619
5 changed files with 29 additions and 60 deletions
|
|
@ -29,25 +29,9 @@ RowLayout {
|
|||
implicitWidth: S.Theme.fontSize + 4
|
||||
implicitHeight: S.Theme.fontSize + 4
|
||||
|
||||
SequentialAnimation {
|
||||
M.PulseAnimation on _pulseOpacity {
|
||||
running: iconItem._needsAttention
|
||||
loops: Animation.Infinite
|
||||
NumberAnimation {
|
||||
target: iconItem
|
||||
property: "_pulseOpacity"
|
||||
to: 0.3
|
||||
duration: 400
|
||||
easing.type: Easing.InOutQuad
|
||||
}
|
||||
NumberAnimation {
|
||||
target: iconItem
|
||||
property: "_pulseOpacity"
|
||||
to: 1
|
||||
duration: 400
|
||||
easing.type: Easing.InOutQuad
|
||||
}
|
||||
onRunningChanged: if (!running)
|
||||
iconItem._pulseOpacity = 1
|
||||
minOpacity: 0.3
|
||||
}
|
||||
|
||||
Item {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue