File tree Expand file tree Collapse file tree 2 files changed +4
-3
lines changed
NavigationCodelab/app/src/main/java/com/example/compose/rally/ui/components
TestingCodelab/app/src/main/java/com/example/compose/rally/ui/components Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -20,8 +20,8 @@ import androidx.compose.animation.core.CubicBezierEasing
2020import androidx.compose.animation.core.LinearOutSlowInEasing
2121import androidx.compose.animation.core.MutableTransitionState
2222import androidx.compose.animation.core.animateFloat
23+ import androidx.compose.animation.core.rememberTransition
2324import androidx.compose.animation.core.tween
24- import androidx.compose.animation.core.updateTransition
2525import androidx.compose.foundation.Canvas
2626import androidx.compose.runtime.Composable
2727import androidx.compose.runtime.getValue
@@ -50,7 +50,7 @@ fun AnimatedCircle(
5050 .apply { targetState = AnimatedCircleProgress .END }
5151 }
5252 val stroke = with (LocalDensity .current) { Stroke (5 .dp.toPx()) }
53- val transition = updateTransition (currentState)
53+ val transition = rememberTransition (currentState)
5454 val angleOffset by transition.animateFloat(
5555 transitionSpec = {
5656 tween(
Original file line number Diff line number Diff line change @@ -20,6 +20,7 @@ import androidx.compose.animation.core.CubicBezierEasing
2020import androidx.compose.animation.core.LinearOutSlowInEasing
2121import androidx.compose.animation.core.MutableTransitionState
2222import androidx.compose.animation.core.animateFloat
23+ import androidx.compose.animation.core.rememberTransition
2324import androidx.compose.animation.core.tween
2425import androidx.compose.animation.core.updateTransition
2526import androidx.compose.foundation.Canvas
@@ -50,7 +51,7 @@ fun AnimatedCircle(
5051 .apply { targetState = AnimatedCircleProgress .END }
5152 }
5253 val stroke = with (LocalDensity .current) { Stroke (5 .dp.toPx()) }
53- val transition = updateTransition (currentState)
54+ val transition = rememberTransition (currentState)
5455 val angleOffset by transition.animateFloat(
5556 transitionSpec = {
5657 tween(
You can’t perform that action at this time.
0 commit comments