Use List/ListItem accessibility role for ordered button strips#311
Open
rezabakhshilaktasaraei wants to merge 1 commit into
Open
Use List/ListItem accessibility role for ordered button strips#311rezabakhshilaktasaraei wants to merge 1 commit into
rezabakhshilaktasaraei wants to merge 1 commit into
Conversation
Rename AbstractButton's page-tab flag to list-item (setIsListItem / isListItem), so a flagged button reports the ListItem role instead of PageTab - mirroring how the menu-button flag maps to ButtonMenu. A list of items matches NVDA's native single-selection list behaviour better than a tab control for the chat-folders strip. Adapt Ui::Accessible::Widget's selection support from PageTabList/PageTab to List/ListItem rather than dropping it: the container exposes QAccessibleSelectionInterface for the List role; select() invokes pressAction() - a list item only implements pressAction, not the toggleAction() Qt's default ListItem path would call - and rejects items that are not selectable, so a locked folder is never claimed as a successful selection. The container's focus / SetFocus forwarding is likewise kept for List, landing focus on the selected item instead of the inert container. A locked folder reports selectable = false.
0b8a6d4 to
97547ab
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Switches the chat-folders strip accessibility model from a tab control to a list, which matches NVDA's native single-selection list behaviour better.
AbstractButton's page-tab flag to list-item (setIsListItem/isListItem), so a flagged button reports theListItemrole instead ofPageTab— mirroring how the menu-button flag maps toButtonMenu.QAccessibleSelectionInterfaceimplementation and thePageTabListfocus /SetFocusforwarding fromUi::Accessible::Widget. AListcontainer is handled by Qt's bridge through the defaultstate().selectedpath, so the custom selection interface isn't needed. The attributes (orientation) interface is kept.Paired with the tdesktop change that gives the folders container the
Listrole and wires each folder as aListItem.