The problem is that if i Linkify the textView the underliyng ScrollView don’t listen the sweep Gestures I’ve setted.Is there a way to have Linkify without messing with the underliyng view’s gestures?
I tried to override ontouchEvent and return false to ACTION_MOVE but the scrollview’s gesture needs the ACTION_DOWN and ACTION_UP event to function. Is there a way to achieve that?
The problem is that if i Linkify the textView the underliyng ScrollView don’t listen
Share
Linkifyapplies to a movementMethod to the textViewLinkMovementMethod. That movement method thought it implements a scrolling vertically method it overrides any other scrolling method the parent has. AlthoughtouchEventcan be dispached to the parent, the specific parentScrollViewneeded the whole sequenceACTION_DOWN,ACTION_MOVE,ACTION_UPto perform (sweep detection).So the solution to my problem is after Linkify to remove the textView’s scrolling method and handle the
LinkMovementMethodlink detection action inonTouchEventof the textView.This way i have the Link_Click detection (performed only with the user touches the link and not the whole textview) and i don’t have the whole LinkMovementMethod.