1
0
mirror of https://github.com/AvengeMedia/DankMaterialShell.git synced 2026-05-03 11:02:08 -04:00

optimize some animations

This commit is contained in:
bbedward
2026-05-01 18:37:17 -04:00
committed by purian23
parent 7c9ca60e44
commit 386a2d0469
12 changed files with 79 additions and 110 deletions

View File

@@ -148,19 +148,16 @@ DankPopout {
opacity: enabled ? 1.0 : 0.5
onClicked: SystemUpdateService.checkForUpdates()
RotationAnimation {
target: refreshButton
property: "rotation"
RotationAnimator on rotation {
from: 0
to: 360
duration: 1000
running: SystemUpdateService.isChecking
loops: Animation.Infinite
running: SystemUpdateService.isChecking
onRunningChanged: {
if (!running) {
if (!running)
refreshButton.rotation = 0;
}
}
}
}

View File

@@ -73,20 +73,17 @@ BasePill {
return root.isActive ? Theme.primary : Theme.surfaceText;
}
RotationAnimation {
RotationAnimator on rotation {
id: rotationAnimation
target: statusIcon
property: "rotation"
from: 0
to: 360
duration: 1000
running: root.isChecking
loops: Animation.Infinite
running: root.isChecking
onRunningChanged: {
if (!running) {
if (!running)
statusIcon.rotation = 0;
}
}
}
}
@@ -130,20 +127,17 @@ BasePill {
return root.isActive ? Theme.primary : Theme.surfaceText;
}
RotationAnimation {
RotationAnimator on rotation {
id: rotationAnimationHorizontal
target: statusIconHorizontal
property: "rotation"
from: 0
to: 360
duration: 1000
running: root.isChecking
loops: Animation.Infinite
running: root.isChecking
onRunningChanged: {
if (!running) {
if (!running)
statusIconHorizontal.rotation = 0;
}
}
}
}