Skip to content

Commit

Permalink
Merge e86ba5e into f47dd5c
Browse files Browse the repository at this point in the history
  • Loading branch information
codeofdusk authored Aug 16, 2022
2 parents f47dd5c + e86ba5e commit 89c42fd
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 3 deletions.
8 changes: 7 additions & 1 deletion source/UIAHandler/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
import ctypes
import UIAHandler
import weakref
import winVersion
from functools import lru_cache
from logHandler import log
from .constants import WinConsoleAPILevel
Expand Down Expand Up @@ -355,4 +356,9 @@ def _getConhostAPILevel(hwnd: int) -> WinConsoleAPILevel:
def _shouldSelectivelyRegister() -> bool:
"Determines whether to register for UIA events selectively or globally."
setting = config.conf['UIA']['eventRegistration']
return setting == "selective"
if setting == "selective":
return True
elif setting == "global":
return False
else:
return winVersion.getWinVer() >= winVersion.WIN11_22H2
2 changes: 1 addition & 1 deletion source/gui/settingsDialogs.py
Original file line number Diff line number Diff line change
Expand Up @@ -2662,7 +2662,7 @@ def __init__(self, parent):
# Translators: A choice in a combo box in the advanced settings
# panel to have NVDA decide whether to register
# selectively or globally for UI Automation events.
_("Automatic (globally)"),
_("Automatic (prefer selectively)"),
# Translators: A choice in a combo box in the advanced settings
# panel to have NVDA register selectively for UI Automation events
# (i.e. not to request events for objects outside immediate focus).
Expand Down
4 changes: 4 additions & 0 deletions user_docs/en/changes.t2t
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,10 @@ What's New in NVDA
- NVDA will now correctly announce Group boxes in Java applications. (#13962)
- Caret properly follows spoken text in say all in applications such as Bookworm, WordPad, or the NVDA log viewer. (#13420, #9179)
- In programs using UI Automation, partially checked checkboxes will be reported correctly. (#13975)
- Improved performance and stability in in Microsoft Visual Studio, Windows Terminal, and other UI Automation based applications. (#11077, #11209)
- These fixes apply to Windows 11 Sun Valley 2 (version 22H2) and later.
- Selective registration for UI Automation events and property changes now enabled by default.
-
-


Expand Down
2 changes: 1 addition & 1 deletion user_docs/en/userGuide.t2t
Original file line number Diff line number Diff line change
Expand Up @@ -2122,7 +2122,7 @@ This button is only enabled if NVDA is configured to enable loading custom code

This option changes how NVDA registers for events fired by the Microsoft UI Automation accessibility API.
The registration for UI Automation events and property changes combo box has three options:
- Automatic: Currently equivalent to "globally".
- Automatic: "selectively" on Windows 11 Sun Valley 2 (version 22H2) and later, "globally" otherwise.
- Selectively: NVDA will limit event registration to the system focus for most events.
If you suffer from performance issues in one or more applications, We recommend you to try this functionality to see whether performance improves.
However, on older versions of Windows, NVDA may have trouble tracking focus in some controls (such as the task manager and emoji panel).
Expand Down

0 comments on commit 89c42fd

Please sign in to comment.