PinchToZoom
PinchToZoom copied to clipboard
Not working onClickListener
I tried to detect onClick event on imageView, but it is not working. How can I fix this issue?
Here is my code.
ImageMatrixTouchHandler imageMatrixTouchHandler = new ImageMatrixTouchHandler(imageView.getContext()); imageView.setOnTouchListener(imageMatrixTouchHandler);
imageView.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {
//do something
}
});
I have pushed functionality for this to the develop
branch. Add this line when you set a click listener to the image view:
imageMatrixTouchHandler.setConsumeTouchEvent(false);
All touch events should be available for click detection like this. The resulting behavior is however quite buggy. I'm looking into ways for making it work better.
@martinwithaar any update on this? When will this be "generally" available?
Can you update click event in master and update versoin ?