Fix selection crash in GestureSelectionHelper MotionEvent handling.

Pull in this changes from ag/4276105.

Fixes: 79945297
Test: atest GestureSelectionHelperTest and manual

Issue: FP2P-534
Change-Id: Ia132f7fcc1093e160f285d9ad3e35c0986d3ff81
(cherry picked from commit c45f5efa6182ecb098b5ca67a4f58c6bd1bcb1b8)
2 files changed