Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
213 views
in Technique[技术] by (71.8m points)

Android single- and multi-stroke gestures in the same library confuses the GesturesOverlayView?

I have noticed a problem on various handsets that if you save gestures while the stroketype is set to single and then change the stroketype to multi and add some multi-stroke gestures, the multi ones are often not recognized by the GesturesOverlayView when you draw them. These can be very simple gestures such as a + or an X. What happens is that the gesture you draw stays faded as if it has not been recognized even though it can be a perfect match.

I know that multi-stroke works okay so I am wondering if the problem is caused by having mixed ones in the library and changing the stroke-type of the view on the fly. Is it possibly confusing it with a single-stroke gesture in the same library but because the match is not close enough, just giving up?

Has anyone had a similar experience or a theory as to what might be happening?

question from:https://stackoverflow.com/questions/3148067/android-single-and-multi-stroke-gestures-in-the-same-library-confuses-the-gestu

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

check android:gestureStrokeLengthThreshold ="15.2"

android:gestureStrokeType="multiple" and

android:fadeOffset="6000"


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...