NativeScript pinchMove gesture event


#1

Is there any pinchMove gesture event? It’s needed for something like instagram zoom. I couldn’t find anything in the docs.

I tried args.getFocusX() , but it gives focused finger’s location. Also I opened a github issue here , but the answer was not related to pinch moving.

Any idea?


#2

Hi @vahid.vdn,

You can find the documentation for pinch gesture here.

You can access to getFocusX(): number and getFocusY(): number; which will give you the position of the finger as you said but you can also use scale: number.

Behind scale there is in Android:

getScaleFactor(): Return the scaling factor from the previous scale event to the current event.

And in iOS:

var scale: CGFloat { get set }: The scale factor relative to the points of the two touches in screen coordinates.

Should fit your needs :slight_smile:


#3

Are you sure it’s related to scale property? It’s a number like 1, 1.5, 2 etc. The scale of the finger. Not the position of the fingers for pinch moving.