Algorithm to implement kinetic scrolling

后端 未结 5 538
耶瑟儿~
耶瑟儿~ 2021-01-30 03:09

What are some good algorithms for creating a kinetic scrolling implementation? The feature would be tested on a custom UI list. While I am targeting mobile devices (those that d

5条回答
  •  终归单人心
    2021-01-30 04:11

    Well i think it would be something like a) get velocity of how fast user scrolled b) when he leaves his finger, auto scroll the list but with a decreasing velocity with an initial velocity of what the user had.

提交回复
热议问题