Skip to content

appModules/SearchUI: add support for announcing suggestion count in Windows 10 Version 1909 and later#10349

Merged
feerrenrut merged 12 commits into
nvaccess:masterfrom
josephsl:i10341searchuiWinTen1909
Jul 8, 2021
Merged

appModules/SearchUI: add support for announcing suggestion count in Windows 10 Version 1909 and later#10349
feerrenrut merged 12 commits into
nvaccess:masterfrom
josephsl:i10341searchuiWinTen1909

Conversation

@josephsl
Copy link
Copy Markdown
Contributor

@josephsl josephsl commented Oct 8, 2019

Link to issue number:

Fixes #10341

Summary of the issue:

In Windows 10 Version 1909, File Explorer gains ability to search OneDrive content via Windows Search, with a live region used to provide suggestion count announcement.

Description of how this pull request fixes the issue:

In Windows 10 Version 1909 (build 18363) and later, File Explorer gains ability to search OneDrive content. This is powered by an embedded Windows Search feature (SearchUI.exe) with a live region announcing suggestion count. This live region has no label, but the child object does, thus coerce the name of this object to be the name of its child, which then allows live region change event to work.

Testing performed:

Tested in Version 1909 (build 18363) and via Windows 10 App Essentials add-on.

Known issues with pull request:

None

Change log entry:

Possibly either new features or changes:

In Windows 10 Version 1909 (change this wording to marketing name once 1909 comes out), NVDA will announce suggestion count when performing searches in File Explorer. (#10231

@LeonarddeR
Copy link
Copy Markdown
Collaborator

Is this somehow related to #8472?

@josephsl
Copy link
Copy Markdown
Contributor Author

josephsl commented Oct 23, 2019 via email

@josephsl
Copy link
Copy Markdown
Contributor Author

josephsl commented Oct 23, 2019 via email

@josephsl
Copy link
Copy Markdown
Contributor Author

Hi,

It is ready for another round of review after 2019.3 is released. Thanks.

@josephsl
Copy link
Copy Markdown
Contributor Author

Hi,

Indeed, 2019.3 was released.

Thanks.

…indows 10 Version 1909. Re nvaccess#10341.

In Windows 10 Version 1909 (build 18363) and later, File Explorer gains ability to search OneDrive content. This is powered by an embedded Windows Search feature (SearchUI.exe) with a live region announcing suggestion count. This live region has no label, but the child object does, thus coerce the name of this object to be the name of its child, which then allows live region change event to work.
@josephsl josephsl force-pushed the i10341searchuiWinTen1909 branch from ddbcfcb to 2021633 Compare February 16, 2020 10:27
@feerrenrut feerrenrut added enhancement app/windows-interface Interactions between NVDA and the default Windows GUI labels Apr 8, 2020
@josephsl
Copy link
Copy Markdown
Contributor Author

josephsl commented May 6, 2020

Hi,

Update: I haven't forgotten about this PR - it's just that more important pull requests came along and developers are going through backlog.

Thanks.

@josephsl josephsl changed the title appModules/SearchUI: add support for announcing suggestion count in Windows 10 Version 1909 appModules/SearchUI: add support for announcing suggestion count in Windows 10 Version 1909 and later Jun 17, 2020
@AppVeyorBot
Copy link
Copy Markdown

See test results for failed build of commit f3a275b085

@AppVeyorBot
Copy link
Copy Markdown

See test results for failed build of commit 727743f2b0

@codeofdusk
Copy link
Copy Markdown
Contributor

Any updates on this PR?

@josephsl
Copy link
Copy Markdown
Contributor Author

josephsl commented May 14, 2021 via email

@josephsl
Copy link
Copy Markdown
Contributor Author

Hi,
Never mind about the above comment, as I thought it was #7330. The PR is indeed ready to go - I'd wait for 2021.2 cycle begins before requesting another formal review.

Thanks.

@josephsl josephsl requested a review from a team as a code owner May 14, 2021 05:20

def event_NVDAObject_init(self, obj):
if isinstance(obj, UIA):
# #10341: Build 18363 introduces modern search experience in File Explorer.
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.

If this is only available in Build 18363 and later, should this be protected by a check for the windows version? If not, please describe in the comment how this code handles earlier versions. I assume that the UIAAutomationId wont be suggestionCountForNarrator in earlier builds of Windows?

pass
elif isinstance(obj, UIA):
if obj.UIAElement.cachedAutomationID == "SearchTextBox":
if obj.UIAAutomationId == "SearchTextBox":
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.

Perhaps this is only ever true in post 18363 builds?

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.

Can you verify whether this change is applicable to earlier builds? It may need the same windows version check.

@josephsl
Copy link
Copy Markdown
Contributor Author

josephsl commented May 19, 2021 via email

@feerrenrut
Copy link
Copy Markdown
Contributor

Ok. But the problem I want to solve is:
"From the perspective of a code reader, how do they know that this code will only run on the intended versions of windows?"

@josephsl
Copy link
Copy Markdown
Contributor Author

josephsl commented May 20, 2021 via email

josephsl added 2 commits May 20, 2021 02:31
…ble from Windows 10 Version 1909 (build 18363/NOvember 2019 Update). Re nvaccess#10341.

Comment from Reef Turner (NV Access): clarify that Windows Search/suggestion count in File Explorer is available from Windows 10 Version 1909, also split the condition into multiple lines to prepare for Flake8 (lint).
@josephsl
Copy link
Copy Markdown
Contributor Author

josephsl commented May 20, 2021 via email

@josephsl
Copy link
Copy Markdown
Contributor Author

josephsl commented Jul 6, 2021

Hi,

A component of #12585 because searchapp.exe was renamed to searchhost.exe in Windows 11, complete with exact same live region implementation as this PR. Therefore, once this PR is erviewed and merged, it can be applied easily to Windows 11 by introducing an alias app module for searchhost.exe that will import from searchui.py.

Thanks.

@lukaszgo1
Copy link
Copy Markdown
Contributor

@feerrenrut It looks like all changes that you've requested has been addressed. Would it be possible to re-review this?

@feerrenrut feerrenrut self-requested a review July 8, 2021 05:28
@feerrenrut
Copy link
Copy Markdown
Contributor

How to test:

  • Open explorer window Windows + e
  • Press F3 to focus search
  • Type something. Note "10 suggestions available, press down arrow key to access results" announced, this is new.
  • Press down arrow, file name and details should be announced

Copy link
Copy Markdown
Contributor

@feerrenrut feerrenrut left a comment

Choose a reason for hiding this comment

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

Thanks @josephsl

@feerrenrut feerrenrut merged commit d304ed0 into nvaccess:master Jul 8, 2021
@nvaccessAuto nvaccessAuto added this to the 2021.2 milestone Jul 8, 2021
@josephsl josephsl deleted the i10341searchuiWinTen1909 branch July 9, 2021 04:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app/windows-interface Interactions between NVDA and the default Windows GUI enhancement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Windows 10/Windows Search: add support for File Explorer embedded search experience in Version 1909 and later

7 participants