Android Question Set the "SmoothScrollTo" speed of ScrollView2D

TelKel81

Active Member
Licensed User
Maybe this could be done using reflection or javaobject but I'm not skilled enough to find out how.

Any hint ? Thanks a lot.
 

agraham

Expert
Licensed User
Longtime User
A poke around inside the ScrollView2D library shows that the animation is a standard animation whose rate is controlled by the currentAnimationTimeMillis setting obtained from the AnimationUtils class. I assume the value of this setting is used to obtain a consistent animation effect across all animations in the UI and it is probably a bad idea to try to set it for an individual view. I can't find, though I haven't looked very hard, where the value of this setting might be changed except possibly as indicated in the next paragraph.

I actually know nothing about Android's animation mechanism as I loathe animations, it is the first thing I turn off in a new Windows or Android device. There are three animation scale settings in Developer Options that determine the Android animation behaviour. I don't know what effect they have as I always immediately set all three to Off. You could play with them to see what effect they have. I believe they can be set set programmatically (obviously as Developer Options does it!) but the app needs to be flagged as a System app to be allowed to do this.
 
Upvote 0

TelKel81

Active Member
Licensed User
Thanks for the reply. I would have to change the value often because I use the built-in view animations too :(
 
Upvote 0
Top