duanhong169 / ColorPicker

🎨 A color picker for Android. Pick a color using color wheel and slider (HSV & alpha).
Apache License 2.0
361 stars 82 forks source link

May I know what is the idea behind ThrottledTouchEventHandler? #17

Open yccheok opened 4 years ago

yccheok commented 4 years ago

Thank you for producing such wonderful library.

When I look at ThrottledTouchEventHandler, I understand its purpose is to avoid from handling too frequent (Anything not more than 16ms is considered too frequent) ACTION_DOWN and ACTION_MOVE.

But, may I know why do we need to perform such filtering. My initial thought is, perhaps the initial idea is avoiding too frequent call to update(MotionEvent event), which may cause the entire app not responsive.

But, even if I avoid the filtering, I notice the app still as smooth as butter.

Am I missing out something?

Thank you