Skip to content
Commit 7c7898e7 authored by Adrian Roos's avatar Adrian Roos
Browse files

GestureNav: Fix AbsSeekBar thumb exclusion

Fix two issues that caused the exclusion for SeekBar thumbs to be to small and offset
from the thumb:

Account for padding and thumb offset; the thumb drawable is drawn with an offset
from the View's Canvas; the same offset must be applied when udpating the exclusion
rects.

The thumb is typically much smaller than the drag zone; the thumb rect alone doesn't
provide an appropriately large exclusion for reliably hitting it, so it is enlarged
to the height of the seek bar (up to 48dp).

Bug: 138992366
Test: manual, show exclusion zones with: adb shell setprop debug.pointerlocation.showexclusion 150 && adb shell settings put system pointer_location 1
Test: atest android.widget.AbsSeekBarTest
Change-Id: I2b670c6f3f33451bdccdfd3d75a75e90260257ff
parent 33c07d1c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment