Skip to content

For single column SysListViews, ignore column order array as it is not required#13761

Merged
seanbudd merged 5 commits into
masterfrom
fixSingleColumnSysListViews
Jun 9, 2022
Merged

For single column SysListViews, ignore column order array as it is not required#13761
seanbudd merged 5 commits into
masterfrom
fixSingleColumnSysListViews

Conversation

@seanbudd

@seanbudd seanbudd commented Jun 2, 2022

Copy link
Copy Markdown
Member

Link to issue number:

Fixes #13659, #13735

Summary of the issue:

Certain applications don't provide a column order array. For the case of single column list views, a column order array is unnecessary, as a default mapping can be assumed.

Description of how this pull request fixes the issue:

For single column list views, map the first column in the UX, to the first column index: i.e. [0] is the column order array. When fetching from a multi column list view, log an error if the column order array is unknown.

Testing strategy:

Manual testing

Known issues with pull request:

None

Change log entries:

Bug fixes:

- Fix reading single column list view items. (#13659, #13735)

Code Review Checklist:

  • Pull Request description:
    • description is up to date
    • change log entries
  • Testing:
    • Unit tests
    • System (end to end) tests
    • Manual testing
  • API is compatible with existing add-ons.
  • Documentation:
    • User Documentation
    • Developer / Technical Documentation
    • Context sensitive help for GUI changes
  • UX of all users considered:
    • Speech
    • Braille
    • Low Vision
    • Different web browsers
    • Localization in other languages / culture than English

@seanbudd seanbudd requested a review from a team as a code owner June 2, 2022 02:51
@seanbudd seanbudd requested review from michaelDCurran and removed request for a team June 2, 2022 02:51
@CyrilleB79

Copy link
Copy Markdown
Contributor

@seanbudd, if I understand correctly, there has been a regression for some applications (StartisBack and the one in 13735) between 2021.3.5 and 2022.1.
From a user point of view, it would be worth to have a change log item to indicate that this issue has been fixed (or worked around).

@cary-rowen

Copy link
Copy Markdown
Contributor

Just curious, why isn't CI generating the build?

@LeonarddeR

Copy link
Copy Markdown
Collaborator

Just curious, why isn't CI generating the build?

Because this pr is made against another branch (not beta, rc, master)

@seanbudd

seanbudd commented Jun 3, 2022

Copy link
Copy Markdown
Member Author

@seanbudd seanbudd changed the title For SysListViews, map first column to first column when no known column order array For single column SysListViews, ignore column order array as it is not required Jun 3, 2022
@cary-rowen

Copy link
Copy Markdown
Contributor

Hi, @seanbudd

I tested #13735 with the build you provided and it has been fixed.
thanks for your efforts.

Best

@seanbudd seanbudd requested review from feerrenrut and removed request for michaelDCurran June 3, 2022 05:11
@feerrenrut

Copy link
Copy Markdown
Contributor

This is generally because they are a single column list view, and as such, want developers to assume that the column order array is [0] in this case.

I think this is overstating our confidence. To ensure we don't mislead future dev work, can you change this to "we don't know for sure, but this might not be implemented specifically for single column list controls."

@feerrenrut feerrenrut left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall looks good.


def _get__columnOrderArray(self) -> Optional[ctypes.Array]:
return self._getColumnOrderArrayRaw(self.columnCount)
def _getColumn(self, column: int) -> Optional[int]:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the name of this could be more descriptive, and probably needs some docs.
I think the column order is to allow for a presentation based indexing, that maps to a logical/internal indexing of columns. Probably because columns can be reordered.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've changed the name to getMappedColumn and added a docstring.

@cary-rowen

Copy link
Copy Markdown
Contributor

Will NV Access consider creating an NVDA2022.1.1?

@seanbudd seanbudd changed the base branch from cherryPickSysListView32Fix to master June 8, 2022 05:45
@seanbudd seanbudd force-pushed the fixSingleColumnSysListViews branch from 05c0133 to e167c76 Compare June 8, 2022 05:46

@feerrenrut feerrenrut left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good.

return self._getColumnOrderArrayRaw(self.columnCount)
If the column order array cannot be fetched from a multi-column SysListView ,
returns None as a mapped column cannot be determined.
"""

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
"""
@param presentationIndex: Zero based index for the column as presented to the user.
@return: The internal / logical column zero based index for the column.
"""

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed this: note that presentationIndex is actually a one based index, not zero based.

@seanbudd seanbudd linked an issue Jun 9, 2022 that may be closed by this pull request
@seanbudd seanbudd merged commit 47af401 into master Jun 9, 2022
@seanbudd seanbudd deleted the fixSingleColumnSysListViews branch June 9, 2022 02:52
@nvaccessAuto nvaccessAuto added this to the 2022.2 milestone Jun 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

NVDA2022.1 fails to report list items in some ListViews StartisBack application fails to speak menu items

6 participants