Merge "Add null check for MotionEvent#getDevice."