I am working on a feature in my app that does zoom-in and zoom-out. I have noticed that when I do zoom-in, then my app receives onScaleEnd() even though both my fingers are still on the screen. Because of this, my app behaves in an unexpected way. I have tested it on Nexus 5 Android emulator and Google pixel tablet. Note that when doing zoom-out, onScaleEnd() event is received as expected when I remove any one of the fingers from the screen.
Can anyone suggest why it is happening or is it a known android bug and how to workaround/fix it?