I am working on a map application and have been implementing all the common 
gestures.

However I have got stuck on the fling gesture for scrolling the map.

I initially used the android.widget.Scroller class as reccomended in the 
SDK to implement the fling animation, however I found that it was not 
flexible enough for what I need. (Specifically it takes int pixels where my 
map uses transformations with floats in metres).

All my other gestures such as zoom and pan to point (ie single tap) I have 
implemented using the awesome ObjectAnimator class.

However I cannot see how to do a fling with it. Mainly that for a fling you 
start with a start velocity that decelerates which means the animation time 
depends on that velocity. Where ObjectAnimator starts with an animation 
time.

Also the current fling animation used (see 
https://github.com/android/platform_frameworks_base/blob/master/core/java/android/widget/Scroller.java)
 
is *really* complicated and looks to be difficult to implement.

So what is the recommended way to get fling animations using ObjectAnimator?
How have other people done map flings?

-- 
-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Android Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-developers+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to