I have a parent UIViewController
to which I add four child view controllers. I’m trying to manage accessibility throughout those controllers. I have a status
enum which keeps track of which of those children are visible on-screen, so when that changes, I’m updating the accessibilityElementsHidden
of the children as appropriate, and sending a LayoutChanged
notification.
My question relates to implementing the UIAccessibilityContainer
protocol in both the parent view controller, and inside each of the child view controllers. The parent needs to know in which order those elements should be presented, etc., and each child has its own elements that also need specific ordering.
It appears that inside the children, the UIAccessibilityContainer
methods (accessibilityElementCount
et al), are never called, so it looks like it’s ignoring them, which leaves my elements out of order and messy.
Is this how it’s supposed to be? Could I possibly be doing something wrong here?