I need to use reverse() method of Android AnimatorSet class. The problem is that this method was added only in api 26. But I found reverse method in source code in package androidx.animation. And I couldn't find any androidx library that allows to use that AnimatorSet (androidx.animation.AnimatorSet). How can I use that class?
How to use androidx.animation.AnimatorSet?
311 Views Asked by Kiryl Tkach At
2
There are 2 best solutions below
0
Robert
On
If you don't care it's still in alpha, you can import it from here:
// To use the Animator APIs
implementation "androidx.core:core-animation:1.0.0-alpha01"
// To test the Animator APIs
androidTestImplementation "androidx.core:core-animation-testing:1.0.0-alpha01"
```
Related Questions in ANDROID
- Delay in loading Html Page(WebView) from assets folder in real android device
- MPAndroidChart method setWordWrapEnabled() not found
- Designing a 'new post' android activity
- Android :EditText inside ListView always update first item in the listview
- Android: Transferring Data via ContentIntent
- Wrong xml being inflated android
- AsyncTask Class
- Unable to receive extras in Android Intent
- Website zoomed out on Android default browser
- Square FloatingActionButton with Android Design Library
- Google Maps API Re-size
- Push toolbar content below statusbar
- Android FragmentPagerAdapter Circular listview
- Layout not shifting up when keyboard is open
- auDIO_OUTPUT_FLAG_FAST denied by client can't connect to localhost
Related Questions in ANIMATION
- Animation in Java on top of JPanel
- Unexpected CALayer Vertical Flipping on 3D Rotation 'Bounce'
- Removing flashiness/ shakiness from scrolling text
- Animation text fade-in other text
- iOS UITableViewCell setSelected:animated: always has animated = NO
- Animation Trigger (Storyboard + Trigger) in C#
- How to animate a ball along the curved path using css3 animation?
- Animation issue on iOS 7 but not on iOS 8
- Asp.net /JQuery to show/hide animated gif before download
- Set animation YDelta in Java class?
- CSS Transition Animation Content Overlapping
- jQuery background animation - better performance
- Android listview top to down animation flashing when animating?
- How can i do a fill animation in Xamarin.Forms
- Create Page custom animations in Windows Phone 8.1 (Windows Runtime)
Related Questions in ANDROIDX
- MotionLayout with recyclerview make onBindViewHolder get called many many times
- Border not appearing around MaterialCardView
- Why can't migrate my flutter project to androidx?
- Can I mix SingleChildScrollview with Pageview
- Bridging Android CameraX into React Native
- Appcompat activity along with androidx gradle version issue in android studio
- AndroidX - Simulate Preference Click Programmatically
- Is there an annotation that denotes a max Android API version?
- error: cannot find symbol import androidx.core.widget.SwipeRefreshLayout; after migrating to androidx
- Annotation process feature not working since androidX upgrade
- Detect swiping out of bounds in Android's ViewPager2
- gradle fail to sync due to dependencies fail
- Custom Row Adapter in androidx.preference.ListPreference
- Closed :Android: App keeps crashing when using com.google.android.material below android 9 (sdk 29)
- How to detect when user pastes something when application is running in the background?
Related Questions in ANDROID-JETPACK
- Android: How to detect how long workmanager is already in enqueue mode?
- Jetpack Compose: Nested weight in custom component
- How can I write a extension function to instantiate a AndroidViewModel in Kotlin?
- Is it possible to "Scale" width and height any widget in jetpack compose?
- How to display back button when navigating to self with navigation component?
- Android: Benefits of DataStore over SharedPreferences
- How to auto-save a form on Android - Best practices
- Resources$NotFoundException with include-dynamic navigation graph
- Android: LiveData postValue() getting null
- Android error : java.lang.IllegalStateException: Function not found androidx.compose.runtime.derivedStateOf in build.gradle
- Data Binding and: Input field validation and manipulation; Activity/Fragment Navigation
- How to represent Observable.empty() with LiveData in Android?
- Navigation Components Child NavHost Fragments' view not shown in Parent NavHost Fragment View
- Espresso pressBack() to check if back navigation works with Jetpack Navigation Component
- Kotlin “toString()” Not Available in Android DataBinding
Related Questions in ANIMATORSET
- Android Studio ObjectAnimator doesn't work twice with same shift
- How to skip to next Animation in AnimatorSet
- How to get tranlationX and translationY from AnimatorListener on animationEnd?
- How to playSequentially a list of AnimatorSet?
- Change Value in ObjectAnimator of AnimatorSet programmatically
- Rotating and scaling a drawable using android ObjectAnimator
- Restart AnimatorSet of AnimatedVectorDrawableCompat
- Animating an ImageView with a "V" shaped animation
- How can I identify objects in the resulting ArrayList of AnimatorSet.getChildAnimations()?
- How to add a delay between animations in AnimatorSet playSequentially()?
- Use the same object animator property (translationx) twice on one object at the same time
- How can I move to ImageViews in android so that they are dependent on each other?
- Animate ImageButton back to initial position
- What's the difference between AnimatorSet's and Object/ValueAnimator's duration?
- Android AnimatorSet.cancel() does not work on Marshmallow version devices
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
For
Api >=26you just create anAnimatorSetobject and after you define the animation you call reverse on it:For older APIs you just reverse the order within the
.ofFloatmethods in yourObjectAnimators:If initially you have
ObjectAnimator.ofFloat(0, 1)you change it toanimator.setFloatValues(1, 0)