由于辅助功能设置未检测到iOS手势 [英] iOS Gesture not detected due to accessibility settings

查看:91
本文介绍了由于辅助功能设置未检测到iOS手势的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在开发的应用需要三点滑动手势.

An app I am developing requires a three-point swipe gesture.

我已经成功地使用UIGestureRecognizer实现了该功能,并且在大多数情况下都可以正常工作.

I have successfully implemented this using a UIGestureRecognizer and it works fine for the most part.

但是,如果将设备的缩放"可访问性设置切换为(设置">常规">可访问性">缩放"),则会停止识别手势.

However, if you switch the device Zoom accessibility setting on (Settings > General > Accessibility > Zoom) this stops the gesture from being recognized.

缩放功能使用各种三点手势进行操作,因此我可以理解它取代了我的应用程序手势.

The Zoom function uses various three-point gestures to operate, so I can understand this superseding my app gesture.

但是,有谁知道我如何确定缩放"设置是否已打开(或执行了缩放辅助功能手势),因此我至少可以建议用户该手势不会被识别?

However, does anyone know how I can determine if the Zoom setting is turned on (or the zoom accessibility gesture performed) so I can at least advise the user that the gesture will not be recognized?

谢谢!

推荐答案

如果您的目标是iOS 5,请查看UIAccessibilityRegisterGestureConflictWithZoom().虽然它不会告诉您是否启用了缩放功能,但会在发生冲突时通知您的用户.

If you're targeting iOS 5, take a look at UIAccessibilityRegisterGestureConflictWithZoom(). While it doesn't tell you if Zoom is enabled, it will let your users know when there's a conflict.

这篇关于由于辅助功能设置未检测到iOS手势的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆