Re: Customize element order
Re: Customize element order
- Subject: Re: Customize element order
- From: Dan Golden via Accessibility-dev <email@hidden>
- Date: Fri, 15 Dec 2023 08:57:03 -0800
Can you try setting the axElements to be button, view, tableView? AXElements
doesn’t need to be a list of leaf nodes. If you put the table view at the end
of the list, VO will go into that view and search for its children, and order
its children after view 2.
> On Dec 15, 2023, at 8:50 AM, Ortwin Gentz via Accessibility-dev
> <email@hidden> wrote:
>
> Hello,
> I've the following view that can be expanded or collapsed when tapping Button:
>
> collapsed:
>
> - Button
> - View 2
>
> Expanded:
>
> - Button
> - View 2
> - Table View with n cells
>
> How can I include the table view cells in my Voice Over element order? By
> default, Voice Over skips the Table View. However, when specifically hovering
> over a Table View cell, VO speaks it.
>
> I tried this:
>
> var axElements: [Any] = [button, view1]
> if expanded, let tableView, let elements = tableView.accessibilityElements {
> axElements += elements
> }
> view.accessibilityElements = axElements
>
> The problem is that tableView.accessibilityElements is nil, so the cells are
> not added.
>
> Any idea how I can accomplish this?
>
> Best Regards,
> Ortwin
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Accessibility-dev mailing list (email@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Accessibility-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden