iOS更改可访问性焦点。 [英] iOS change accessibility focus.
本文介绍了iOS更改可访问性焦点。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
有没有办法以编程方式设置辅助功能焦点(App Store-safe)?任何帮助将不胜感激。
is there a way to set the accessibility focus programatically (App Store-safe)? Any help will be greatly appreciated.
推荐答案
专注于你可以打电话的元素。
To focus on element you can call.
UIAccessibilityPostNotification(UIAccessibilityScreenChangedNotification, self.myFirstElement);
否则对于iOS 8+,使用accessibilityElements设置元素顺序,它将自动聚焦于第一个元素列表
Otherwise for iOS 8+ use the accessibilityElements to set element order and it will focus automatically on first element in the list
self.accessibilityElements = @[myFirstView, mySecondButton, myThirdLabel]
这篇关于iOS更改可访问性焦点。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文