question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Add resetter for minFrame/maxFrame properties

See original GitHub issue

Is your feature request related to a problem? Please describe. Programatically I first want something to loop, so I set a min and max frame, but after a specific action, I want to play the remaining end of the animation and stop looping.

Describe the solution you’d like Either add a resetMinFrame()/resetMaxFrame() or if the lib would be in kotlin make the setMinFrame()/setMaxFrame() methods have an optional argument, that when not specified, resets the min/max values.

Describe alternatives you’ve considered Create a kotlin extension with this code:

fun LottieAnimationView.resetMaxFrame() {
    val frames = this.composition?.durationFrames?.toInt() ?: 0
    this.setMaxFrame(frames)
}

Additional context None

Lottie is supported and developed on nights and weekends. Please consider sponsoring Lottie to prioritize this issue and help support this issue as well as future investments.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:6

github_iconTop GitHub Comments

1reaction
gpealcommented, Aug 28, 2020

Let me know if that isn’t sufficient for you.

0reactions
carstenhagcommented, Nov 27, 2020

@gpeal Just saw this issue still being referenced in our code, can you please look at the above comment? Still applies. 😃 Thanks!

Read more comments on GitHub >

github_iconTop Results From Across the Web

My Custom CSS Reset - Josh W Comeau
I have a set of baseline CSS styles that come with me from project to project. In the past, I'd use a typical...
Read more >
PropertyGrid - how to add ability to reset property of collection ...
Is it possible to allow user to reset the property in design-time via property grid? The reset method: void ResetWorkTimeRules() { TimeRules.
Read more >
counter-reset - CSS: Cascading Style Sheets - MDN Web Docs
The counter-reset CSS property resets a CSS counter to a given value. This property will create a new counter or reversed counter with...
Read more >
CSS Tip #1: Resetting Your Styles with CSS Reset - WebFX
Reset CSS is the process of resetting the styles of all elements to a baseline value to avoid cross-browser differences. Learn more here!...
Read more >
An Interview With Elad Shechter on "The New CSS Reset"
This operation removes all the default user-agent-stylesheet styles that the browser is adding. To understand these substantial new CSS powers, ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found