Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix issue with certain SECTION elements not being recognized as editable controls in Visual Studio Code #17572

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 4 additions & 6 deletions source/appModules/code.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,8 @@ def chooseNVDAObjectOverlayClasses(self, obj, clsList):
clsList.insert(0, VSCodeDocument)

def event_NVDAObject_init(self, obj: NVDAObject):
# This is a specific fix for Visual Studio Code,
# However, the root cause of the issue is issue #15159.
# Once issue #15159 is fixed,
# The PR #16248 that introduced this code can be immediately reverted.
# (see issue #15159 for full description)
if obj.role != controlTypes.Role.EDITABLETEXT:
# TODO: This is a specific fix for Visual Studio Code.
# Once the underlying issue is resolved, this workaround can be removed.
# See issue #15159 for more details.
if obj.role != controlTypes.Role.EDITABLETEXT and controlTypes.State.EDITABLE not in obj.states:
obj.TextInfo = NVDAObjectTextInfo
Loading