Detect tap (no click) in the center of siri remote

Hello.

In the native video player you detect any tap from siri remote for hide or unhide the player controls, even in the center.


It´s possible detect a tap (no click) in the center? I saw UIPressTypeUpArrow,UIPressTypeDownArrow,UIPressTypeLeftArrow,UIPressTypeRightArrow, but don´t detect any touch around the center. It´s this unavailable for developers?


Thanks.

Accepted Reply

You can use a tap gesture recognizer to listen for touches, just make sure to set the gesture's allowedTouchTypes property to include UITouchTypeIndirect, and set the allowedPressTypes property to be an empty array. You won't, however, be able to detect the location of the user's finger on the trackpad: the touch will always begin at the center of the focused view, regardless of where the user's finger begins to touch the trackpad. If you need the absolute location on the trackpad, you should definitely file a radar that explains what you're trying to accomplish and how the finger location would help you.

Replies

You can use a tap gesture recognizer to listen for touches, just make sure to set the gesture's allowedTouchTypes property to include UITouchTypeIndirect, and set the allowedPressTypes property to be an empty array. You won't, however, be able to detect the location of the user's finger on the trackpad: the touch will always begin at the center of the focused view, regardless of where the user's finger begins to touch the trackpad. If you need the absolute location on the trackpad, you should definitely file a radar that explains what you're trying to accomplish and how the finger location would help you.

Thanks.


That is I need.